flattspott
Feb 29 2004, 01:24 AM
I see the stuff in the ActionScriptReadMe.txt but it's got me confused.
LoadDialogFromXML <UIHandle> <XMLHandle> <XMLLocation>
Now would this be how it works if you had multiple dialogs in one XML file?
XMLOpen ScriptXML $ActualPath$\Scripts\SomeScript\SomeScript.xml
LoadDialogFromXML FirstDLG ScriptXML !.FirstDialogToLoad
LoadDialogFromXML SecongDLG ScriptXML !.SecondDialogToLoad
Is the XMLHandle like a Variable of sorts for the main script\dialog xml file location? That way you don't have to keep specifying the file location whenever you want to create a dialog? And does this mean that if you use XMLClose then your dialog will mess up (Like you can't GET or SET values)?
BenJeremy
Feb 29 2004, 02:05 AM
| QUOTE (flattspott @ Feb 28 2004, 10:24 PM) |
I see the stuff in the ActionScriptReadMe.txt but it's got me confused. LoadDialogFromXML <UIHandle> <XMLHandle> <XMLLocation>
Now would this be how it works if you had multiple dialogs in one XML file?
XMLOpen ScriptXML $ActualPath$\Scripts\SomeScript\SomeScript.xml LoadDialogFromXML FirstDLG ScriptXML !.FirstDialogToLoad LoadDialogFromXML SecongDLG ScriptXML !.SecondDialogToLoad
Is the XMLHandle like a Variable of sorts for the main script\dialog xml file location? That way you don't have to keep specifying the file location whenever you want to create a dialog? And does this mean that if you use XMLClose then your dialog will mess up (Like you can't GET or SET values)? |
The example you types in is exactly how it's used.
You open an XML object, then create new Dialog UI Objects from nodes within the XML.
Alternatively, you might have:
| CODE |
XMLOpen ScriptXML $ActualPath$\Scripts\SomeScript\SomeScript.xml LoadDialogFromXML FirstDLG ScriptXML !.Dialogs.Dialog?DlgID=IPSetupOne LoadDialogFromXML SecongDLG ScriptXML !.Dialogs.Dialog?DlgID=IPSetupTwo
|
to take advantage of the new query locational method.
...and yes, you should keep the XML object around for the life of the dialogs, unless it's an internal XML node.
flattspott
Feb 29 2004, 03:11 AM
So what I had would work then, but I could also do it the other way you posted?
BenJeremy
Feb 29 2004, 03:23 AM
| QUOTE (flattspott @ Feb 29 2004, 12:11 AM) |
| So what I had would work then, but I could also do it the other way you posted? |
Exactly.
I added the query format because it's far superior for tracking dialogs and controls within nodes.
flattspott
Feb 29 2004, 05:50 PM
Yes it is superior. No more counting nodes and forgetting to start at 0.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.