PCode Posted February 17, 2010 Share Posted February 17, 2010 (edited) Basically I want to sort data into a treeview. Ideally it would look something like this Essay -Paragraph 1 --Sentence 1 ---Word 1 ---Word 2 ---Word 3 --Sentence 2 ---Word 1 ---Word 2 ---Word 3 ---Word 4 -Paragraph 2 ... I think that should give you the picture. The number of paragraphs in an essay, sentences in a paragraph, and words in a sentence however are unknown. One thing I've considered is a multidimensional array, but wouldn't I have to have every sentence store the same amount of words as the sentence with the highest amount of words? I've also considered arrays of arrays, but wouldn't I have a create a dummy array every time I wanted to go a dimension further into the array? So either correct me if I'm mistaken, suggest a better way of storing this data, or tell me that I'm just between a rock and a hard space. Edited February 17, 2010 by PCode Link to comment Share on other sites More sharing options...
PsaltyDS Posted February 17, 2010 Share Posted February 17, 2010 Sounds like an XML file would do nicely. Have you any experience with _XMLDOMWrapper.au3 UDF or XPath syntax? Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
water Posted February 17, 2010 Share Posted February 17, 2010 I once used this code to populate a Treeview.Every line starts with a #. The number of spaces denote the level in the tree. No space = top level, 1 space = child of top level etc. My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now