|
-
[F8] Radio Button data to Dynamic text box?
I have 2 radio buttons (yes and no) in group: radioGroup. instance name is yes and no. Data is "ok" and "not ok".
I have a button that when pressed populates a dynamic text box with information. What I can't get is how to get Flash to see which radio is ticked and display the data info there.
Ideas?
~MoN
If I am wrong, please just correct me and move on.. there is no need for all that pointing and laughing! ~MoN
-
No ideas? perhaps it is just the coding, maybe I am doing something wrong? Maybe it isn't possible?
Any help is appreciated!
~MoN
If I am wrong, please just correct me and move on.. there is no need for all that pointing and laughing! ~MoN
-
Okay, I figured it out! Woot!
I have the 2 radio buttons, Yes and No are the text values next to them. radioGroup is the group ID, and all others are default.
I dragged the radio button to the stage (both instances, and gave them "yes" and "no" instance names.
Once done with that I made my dynamic text box on the next frame, and gave it a var of myText.
back on frame one I have my radio button and I added this to the AS panel for the radio button:
Code:
on (click) {
_root.userAnswer = "Yes";
}
and for the NO radio I added the same except _root.userAnswer = "No";
Then back in frame 2 I added this to the AS layer:
Code:
myText = "User Name: " + uName + newline + "Do You Play? " + _root.isok;
Now when I go to frame 2 the dynamic text box says:
User Name: {name entered by user}
Do You Play?: {Yes} or {No} depending on what they clicked
Yay! I don't know why it was so damn hard to figure that out!
~MoN
If I am wrong, please just correct me and move on.. there is no need for all that pointing and laughing! ~MoN
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|