Think of something that you wish Authorware could do but it doesn't?  Let the our good friends at Macromedia know via the wishlist.

Please let us know if you find any of the materials on this site inappropriate or offensive. Please include the url and why the material should be reviewed.

Comments and questions about the site are also welcome. Please no Authorware questions, use the AWARE list.


B5010 - How do I pass variables with JumpFileReturn?

by - Joseph Ganci

Thanks for the excellent tutoring last November.

I'm trying to carry variables between two files using JumpfileReturn. Of the ten total variables being carried, two are straight forward and work like a charm. The other eight are part of a Linear List which is part of file 2. I'm having no luck bringing back data to file 1 from the Linear List in file 2 that are part of Details[].

JumpFileReturn(""SessnMgr"", ""Details[7], Details[11], Details[12], etc..., SITREPtab, Newfile"")

will return good values from file 2 for SITREPtab and Newfile but will not update the values for Details[*].

In file two the values in Details[] has an initial value of [] set in the Variables Window and as you work through the file you actually enter new values for all 21 items in the list at various times. So you have valid data in all 21 slots of Details[] by the time you are ready to return to file 1.

I tried to initialize the same data in file 1 by placing Details[] in the Variables Window. I then took a set of actual values from file 2 and used them as initial conditions in file 1 but it still will not update the data when you JFR to file 2.

I also tried the following JFR but had no success.
JumpFileReturn(""SessnMgr"", ""Details[*], SITREPtab, Newfile"") and also
JumpFileReturn(""SessnMgr"", ""Details[], SITREPtab, Newfile"")
but had no luck returning any of the Details[] values.

Is there some secret to using LinearLists identification in JFR that doesn't seem obvious?

Thanks for looking at this.

You're going to kick yourself when you see the answer!

Think of Details as a very extended variable. Therefore, to pass details from one file to the other, just pass the name, like so:

JumpFileReturn(""SessnMgr"", ""Details, SITREPtab, Newfile"")

Do be sure to define Details in SessnMgr as a list as well. The best way to do this is to set its initial value to [] in the New Variable dialog box.

I've tested this and it works. Any changes you make to any of the locations in Details in either file will be reflected in the other.

Thank you for your very simple answer. You were right, of course. It worked like a charm. This was the first time that I had occassion to transfer one of the LinearList variables from one file to another. I've used several Lists to simplify the construction within a file and simply hit a blank wall with this one.

There are 0 reviews
Add your review