Populating a NSMenu with an heirachical NSXMLDocument
Populating a NSMenu with an heirachical NSXMLDocument
- Subject: Populating a NSMenu with an heirachical NSXMLDocument
- From: "John Cassington" <email@hidden>
- Date: Wed, 14 Jun 2006 21:30:28 +1000
Hello,
I have a NSXMLDocument created from the following XML
<xml>
<status>listing_ok</status>
<folder id=\"0\" name=\"MyBox\" shared=\"0\" shared_link=\"\">
<folders>
<folder id=\"1811981\" name=\"Documents\" shared=\"0\"
shared_link=\"\">
<tags></tags>
<folders></folders>
<files></files>
</folder>
<folder id=\"1812046\" name=\"School\" shared=\"0\"
shared_link=\"\">
<tags></tags>
<folders>
<folder id=\"1876523\" name=\"Engineering\" shared=\"0\"
shared_link=\"\">
<tags></tags>
<folders></folders>
<files>
<file id=\"11907763\" file_name=\"Engineering
Workbook.doc\" >
<tags>
<tag id=\"19754\" /><tag id=\"19755\"
/><tag id=\"19756\" />
</tags>
</file>
</files>
</folder>
</folders>
<files>
<file id=\"11907764\" file_name=\"Engineering
Assignment.doc\">
<tags></tags></file>
</files>
</folder>
</folders>
<files></files>
</folder>
<pages>1</pages>
</xml>
... and i want to create a NSMenu with the <folder> items as submenus and
<file> as items of those submenus
i have tried to do this using example code, but i do not have any idea on
how to handle the heirarchy
[aNode level] seemed to have some use, but i am at a loss
Thank you for your help
John Cassington
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden