Adding radio buttons
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Adding radio buttons
After a lapse, I am back to testing RevMedia 4.0.
I had made a project, containing several cards. Now I have decided that I should add a group of radio buttons. Thinking the HC and SC way, I'd go to the background, add the buttons, and that would be that (other than any necessary scripting, of course): all the buttons would be available on all of the cards that shared that background.
In RevMedia I tried adding three radio buttons, grouping them and marking the group to "Behave as background", though worried about the comment in parentheses by this check-box, "Auto-place on new cards…" (my italics): only on new cards?
Indeed, when I look at other cards in the project, they do not contain the new group of radio buttons.
Must new "background" elements be added separately, either manually or through a script, to each existing card?
I had made a project, containing several cards. Now I have decided that I should add a group of radio buttons. Thinking the HC and SC way, I'd go to the background, add the buttons, and that would be that (other than any necessary scripting, of course): all the buttons would be available on all of the cards that shared that background.
In RevMedia I tried adding three radio buttons, grouping them and marking the group to "Behave as background", though worried about the comment in parentheses by this check-box, "Auto-place on new cards…" (my italics): only on new cards?
Indeed, when I look at other cards in the project, they do not contain the new group of radio buttons.
Must new "background" elements be added separately, either manually or through a script, to each existing card?
Re: Adding radio buttons
Hi exheusfden,
AND the group must be on the current card when the new card is being created!
...
place bg "name of new background group here" onto cd 1
...
Best
Klaus
Yes, this applies only to newly created cards!In RevMedia I tried adding three radio buttons, grouping them and marking the group to "Behave as background", though worried about the comment in parentheses by this check-box, "Auto-place on new cards…" (my italics): only on new cards?
AND the group must be on the current card when the new card is being created!
Yes.Must new "background" elements be added separately, either manually or through a script, to each existing card?
...
place bg "name of new background group here" onto cd 1
...
Best
Klaus
Re: Adding radio buttons
Thanks Klaus. That's very disappointing and a huge drawback when compared to the "classic" background use of HC and SC. Good to know before I get too far into Revolution, though.
Re: Adding radio buttons
And can the new group be added to an existing group, so that the resulting group applies to all cards?Klaus wrote:Yes.Must new "background" elements be added separately, either manually or through a script, to each existing card?
...
place bg "name of new background group here" onto cd 1
...
Re: Adding radio buttons
Hi exheusden,
yes, if you add objects to groups that are already placed onto cards, then these cards will of course reflect the changes you made!
Best
Klaus
yes, if you add objects to groups that are already placed onto cards, then these cards will of course reflect the changes you made!
Best
Klaus
Re: Adding radio buttons
Klaus, I've been trying to work out this business of adding objects to groups. Indeed, the Revolution Users Guide states
but I am unable to find any explanation in the guide as to how to actually add an object. Suppose, for example, that I want to add a single button to a large, already existing group: what's the best way to do this?you can add objects to the group or
delete them
Re: Adding radio buttons
1. Select the group where you want to add an object to.
2. Menu "Object" -> Edit group...
(this switches to a special "edit background" mode! Note the change of the windows title!)
3. Add or delete objects to the group
4. Menu "Object" -> Stop editing group
Done
Best
Klaus
2. Menu "Object" -> Edit group...
(this switches to a special "edit background" mode! Note the change of the windows title!)
3. Add or delete objects to the group
4. Menu "Object" -> Stop editing group
Done

Best
Klaus
Re: Adding radio buttons
Thank you, Klaus!
Re: Adding radio buttons
My little development tool, "wizard" does this. You select the group, and it places it on all cards, changing its backgroundbehavior along the way. It's in revOnLine.
Craig Newman
Craig Newman
Re: Adding radio buttons
Craig, just testing Wizard and it returns the error
Perhaps I have an incompatible version of Revolution.
in the mouseUp script of field "doStuff".field "doStuff": execution error at line 16 (do: error in source expression) near "send resumeStack to ", char 1
Perhaps I have an incompatible version of Revolution.
Re: Adding radio buttons
You do not have an incompatible version of Rev!
Problem lies in the scripts of that "Wizard".
If you call/send an handler that is not defined, like "resumestack" to a stack that has NO "resumestack" handler in the message hierarchy, then you get an error!
@Craig
Change all these scripts to a "try" structure and it should work.
Best
Klaus
Problem lies in the scripts of that "Wizard".
If you call/send an handler that is not defined, like "resumestack" to a stack that has NO "resumestack" handler in the message hierarchy, then you get an error!
@Craig
Change all these scripts to a "try" structure and it should work.
Best
Klaus
Re: Adding radio buttons
Hi.
The "wizard" stack is only meant to be used in conjunction with other "working" stacks, never alone. A new download might not have references to anything right out of the box, and errors might pop up if you try to invoke certain functions. Open a stack, and then click wizard. It will track you from that point on. This was my personal tool in HC, and it has no value alone.
The "resumeStack" message is trapped and passed normally, whenever it arises. Klaus, the error comes from not having a valid destination to send the message to, not that the message cannot be handled. I should, however, test for the case when there is no open stack for wizard to track. I just never used in that way.
Also, I should point out that only groups will be added to all cards, not just any old object. I should change this to encompass individual objects as well.
Craig
The "wizard" stack is only meant to be used in conjunction with other "working" stacks, never alone. A new download might not have references to anything right out of the box, and errors might pop up if you try to invoke certain functions. Open a stack, and then click wizard. It will track you from that point on. This was my personal tool in HC, and it has no value alone.
The "resumeStack" message is trapped and passed normally, whenever it arises. Klaus, the error comes from not having a valid destination to send the message to, not that the message cannot be handled. I should, however, test for the case when there is no open stack for wizard to track. I just never used in that way.
Also, I should point out that only groups will be added to all cards, not just any old object. I should change this to encompass individual objects as well.
Craig
Re: Adding radio buttons
Hi Craig,
ah, I see, sorry, I was just guessing from what exheusden wrote
ah, I see, sorry, I was just guessing from what exheusden wrote

Re: Adding radio buttons
Klaus.
No foul; I actually figured as much, knowing your capabilities. I did add a check to make sure there are valid object references, so it was worth it after all.
And one can now make both objects and/or groups into a bg object, which was an oversight.
I agree with exheusden about the background paradigm from HC, though I am slowly getting the group paradigm. It is hard to change one's second nature. That a stack could be partitioned by bg still seems like a fabulous functionality. Anyway, that is exactly why I made that gadget.
Exheusden, please try it once more, with the latest version. As I learned yet again, you cannot test too much...
Craig
No foul; I actually figured as much, knowing your capabilities. I did add a check to make sure there are valid object references, so it was worth it after all.
And one can now make both objects and/or groups into a bg object, which was an oversight.
I agree with exheusden about the background paradigm from HC, though I am slowly getting the group paradigm. It is hard to change one's second nature. That a stack could be partitioned by bg still seems like a fabulous functionality. Anyway, that is exactly why I made that gadget.
Exheusden, please try it once more, with the latest version. As I learned yet again, you cannot test too much...
Craig
Re: Adding radio buttons
Craig, just tried Wizard again and received another error:
This time I opened my own stack after having opened (downloaded) Wizard.
I am, in any case, glad to hear that I'm not alone in finding the bg notion easier to use than that of groups. Perhaps it's just what one is used to.
This time in the mouseUp script of field "Objects".field "Objects": execution error at line 39 (Chunk: error in object expression) near "btn btn "One", char 13
This time I opened my own stack after having opened (downloaded) Wizard.
I am, in any case, glad to hear that I'm not alone in finding the bg notion easier to use than that of groups. Perhaps it's just what one is used to.