Writing radio to a file
Klaus Major
k_major at os.surf2000.de
Tue Nov 5 13:16:01 EST 2002
Hi Timothy,
> Alright. I have figured out how to group radio buttons and set their
> behavior to true you can only have one highlighted. Atleast I did it
> like this. I just grouped them and doubled clicked on one and
> scripted:
> "set the radiobehavior of group to true" That seemed to have worked.
I think even this is not necessary.
Just create some radio-buttons, group them and that's all.
They should act as desired immediately.
I jsut tried it here at home and it worked...
> Now my question is how can I script it to write the choice of a user
> to a file.
> I want to give a little quiz to people and have multiple choice
> questions.
> I want my output to be a text file that they can then send to me or
> even better have rev do
> it. But that might be getting ahead of myself. Anyone have any
> ideas? Thanks.
You can query "the hilitedbuttonname of grp xxx".
This will give you the name of the button that is hilited in that group.
So you can script something like:
on mouseup ## or whatever
put the hilitedbuttonname of grp "the difficult quiz" into
url"file:quizresults.txt"
end mouseup
Don't forget to give the radio-buttons appropriate names ;-)
> -Tim
Hope this helps.
Regards
Klaus Major
k_major at os.surf2000.de
More information about the use-livecode
mailing list