dakota97
Centurion
Hi all,
I'm having problems building the hierarchy of a treeview control from an XML file. I'm basically looking to replicate the same structure that the Windows registry uses (HKEY_Local_Machine/Software/....etc.), but I can't figure out how to build the tree so that I don't duplicate childnodes.
Our tech support team receives XML files with various infomormation retrieved from the end-user's computer. They use this to diagnose hardware compatibility issues with our software, since a lot of it is low-level communication with the hardware. However, it is painstakingly time consuming to read the raw XML that is produced. So, I've been assigned the task of creating a "Support Reader" application that will load the XML file into a "human readable" format.
Ultimately, the application will parse the XML file, and create the tree structure. Then when the user clicks on a specific node, the underlying values will be populated in a listbox or listview control, the same way as seen when navigating through the Windows registry.
So far, I've been able to insert the top-level nodes (all the HKEY ones), and one childnode, but I'm having major difficulties adding additional nodes below that. The big thing is that if the node exists, I don't want to add it a second time.
I've attached the XML file template that I'm using, and would appreciate any pointers or code samples on how I can get this to work.
Thanks in advance,
Chris
I'm having problems building the hierarchy of a treeview control from an XML file. I'm basically looking to replicate the same structure that the Windows registry uses (HKEY_Local_Machine/Software/....etc.), but I can't figure out how to build the tree so that I don't duplicate childnodes.
Our tech support team receives XML files with various infomormation retrieved from the end-user's computer. They use this to diagnose hardware compatibility issues with our software, since a lot of it is low-level communication with the hardware. However, it is painstakingly time consuming to read the raw XML that is produced. So, I've been assigned the task of creating a "Support Reader" application that will load the XML file into a "human readable" format.
Ultimately, the application will parse the XML file, and create the tree structure. Then when the user clicks on a specific node, the underlying values will be populated in a listbox or listview control, the same way as seen when navigating through the Windows registry.
So far, I've been able to insert the top-level nodes (all the HKEY ones), and one childnode, but I'm having major difficulties adding additional nodes below that. The big thing is that if the node exists, I don't want to add it a second time.
I've attached the XML file template that I'm using, and would appreciate any pointers or code samples on how I can get this to work.
Thanks in advance,
Chris