PDA

View Full Version : Components lose value over frames


3dmacguy
05-12-2004, 06:16 AM
I have several components setup on frame one, and on frame two I have another component. All of these components, on both frames 1 and 2, are within the same movieclip. I want to be able to fill out the components on frame 1 and on frame 2 (and be able to go back and forth as necessary) and then when the users are pleased, click submit. Now, however, when I fill out the components (radio buttons and checkboxes) and I change frames, then go back, they are reset to the default null value. Is there any way to make them retain their values once set instead of resetting themselves?

Thanks,
-Josh

sneeuwitje
05-12-2004, 03:53 PM
don't think that can be done ... (mx2004) components always init() onLoad.

You might try adding to a content-object on killFocus of each component in your form and then use that object to init() them with the values therein on return ... [ seems no fun ... ]

Or toggle the appropriate components _visible true/false on the appropriate frame [ or is it that they have overlapping names on different frames ... then you're always in trouble with this kind of interaction]

3dmacguy
05-12-2004, 05:13 PM
Hey sneeuwitje,

thanks for getting back to me. I have managed to get what I was wanting to work to work. basically a lot of work with using if (this is selected) {show this movieclip with the components in them}

The problem now though is that whenever I publish the movie none of the component labels display. The actual radio buttons and check boxes show up, but none of their labels do. Why? I am loading this swf into another swf if this might make a difference.

3dmacguy
05-12-2004, 05:35 PM
Ah. I see I must not have had the latest verion of Flash Player :)

Problem solved!