Back to Four Js Website
Four Js Customer Forum
Subscribe for automatic updates:
RSS
Sign in for full access
|
Help
Four Js Development Tools Forum
>
Discussions by product
>
Genero BDL
>
RADIOGROUP items built dynamically
Most recent posts
Pages: [
1
]
« previous
next »
Reply
|
Print
Author
Topic: RADIOGROUP items built dynamically (Read 24366 times)
Benjamin F.
Posts: 7
RADIOGROUP items built dynamically
«
on:
December 17, 2015, 10:00:22 pm »
I'm trying to change specific items on a RADIOGROUP to be hidden or shown dynamically. I already have the data I need to determine whether they should be shown, but I don't know how to actually show it.
For example if I start with this:
RADIOGROUP rad_type = formonly.rad_type, ITEMS=((1,"1stChoice"),(2,"2ndChoice"), (3,"3rdChoice")), ORIENTATION=HORIZONTAL;
How can I hide 2ndChoice (for example)? I have fooled around with ui.Dialog.setActionHidden and ui.Form.setElementHidden but haven't been able to make the magic happen. Any advice is greatly appreciated. I'm using Genero Mobile 1.1 if that makes a difference.
Bernard M.
Posts: 45
Re: RADIOGROUP items built dynamically
«
Reply #1 on:
December 18, 2015, 05:24:27 pm »
Hi Benjamin,
This is actually not possible, RadioGroup items don't have the hidden attribute at all. Also modifying dynamically the RadioGroup list of items could lead into rendering/layout issues.
You could use a ComboBox instead. And using the ui.ComboBox class you can then add or remove items dynamically with the addItem()/removeItem() methods.
Regards,
Bernard
Nuno G.
Posts: 38
Re: RADIOGROUP items built dynamically
«
Reply #2 on:
December 21, 2015, 11:06:07 am »
Hope this small snipper helps.
Good luck
radiogroup.zip
(4.9 KB - downloaded 1582 times.)
Nuno G.
Posts: 38
Re: RADIOGROUP items built dynamically
«
Reply #3 on:
December 21, 2015, 11:06:51 am »
Hope this small snippet helps
radiogroup.zip
(4.9 KB - downloaded 1514 times.)
Benjamin F.
Posts: 7
Re: RADIOGROUP items built dynamically
«
Reply #4 on:
December 21, 2015, 02:57:40 pm »
Nuno G, that is extremely helpful. I bet there's a lot of stuff that could be customized that way that otherwise can't be. Thank you so much!!
Nuno G.
Posts: 38
Re: RADIOGROUP items built dynamically
«
Reply #5 on:
December 21, 2015, 06:11:33 pm »
My pleasure. Glad I could help.
Pages: [
1
]
Reply
|
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> General Discussion
=> Ask Reuben
=> WWDC21
-----------------------------
Discussions by product
-----------------------------
=> Products announcements
=> Genero BDL
=> GWS
=> GAS and GBC
=> GDC
=> Genero Mobile for Android or iOS
=> Genero Studio
=> Reporting tools (GRW, GRE)
-----------------------------
Jobs
-----------------------------
=> Jobs
Powered by SMF 1.1.21
|
SMF © 2015, Simple Machines
Loading...