Searching Text Using Tab Delimited TXT file dictionary
Posted: Wed Jun 10, 2009 10:13 pm
Hi,
This may not be a good starting project for a beginner, so I thought it would be wise to check.
I can write up a small text file (.txt) that is tab delimited, with a numbered list of word categories (for example, 1=noun, 2=verb, 3=adjective, etc.) and another longer list of common nouns, verbs, adjectives, etc. that the dictionary is screening a block (string) of text for.
New to RunRev, I looked at the RunRev distionary and found matchText and suspect it may be involved in this task?
The block of text would be cut/pasted or dragged by the user into a text entry field, which I think would need to be scripted to write these words as a string into a variable (array?).
Then, once the user, for example clicks a button called "analyze" coded to open the dictionary, read its tab delimited content, analyze the words in the string array for matches in the dictionary and finally report the number of words matched for each word category.
So, for example, a block of text, "Two young boys played soccer." would be analyzed and show the result (hopefully though my grammar is a bit rusty):
noun=2
verb=1
adjective=2
I would appreciate any suggestions regarding level of difficulty for a RunRev beginner, and if this project can be done by a beginner, any help getting started: leads, sample stacks/tutorials to check out, suggestions how to set up a small test version on which to build.
I think this can be a good way to learn, if not too difficult.
Thanks for your help.
Kind Regards,
This may not be a good starting project for a beginner, so I thought it would be wise to check.
I can write up a small text file (.txt) that is tab delimited, with a numbered list of word categories (for example, 1=noun, 2=verb, 3=adjective, etc.) and another longer list of common nouns, verbs, adjectives, etc. that the dictionary is screening a block (string) of text for.
New to RunRev, I looked at the RunRev distionary and found matchText and suspect it may be involved in this task?
The block of text would be cut/pasted or dragged by the user into a text entry field, which I think would need to be scripted to write these words as a string into a variable (array?).
Then, once the user, for example clicks a button called "analyze" coded to open the dictionary, read its tab delimited content, analyze the words in the string array for matches in the dictionary and finally report the number of words matched for each word category.
So, for example, a block of text, "Two young boys played soccer." would be analyzed and show the result (hopefully though my grammar is a bit rusty):
noun=2
verb=1
adjective=2
I would appreciate any suggestions regarding level of difficulty for a RunRev beginner, and if this project can be done by a beginner, any help getting started: leads, sample stacks/tutorials to check out, suggestions how to set up a small test version on which to build.
I think this can be a good way to learn, if not too difficult.
Thanks for your help.
Kind Regards,