|
|
|
Re: search [message #488086 is a reply to message #487942] |
Tue, 04 January 2011 10:42 |
|
memua
Messages: 27 Registered: January 2011 Location: riyadh
|
Junior Member |
|
|
can check this code i wrote but it will still not work
if :NAME_GROUP = 1 THEN
SET_ITEM-PROPERTY('T1',DISPLAYED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T1',ENABLED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T2',ENABLED,PROPERTY_FALSE);
elsif :NAME_GROUP = 2 THEN
SET_ITEM-PROPERTY('T1',DISPLAYED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T2',ENABLED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T1',ENABLED,PROPERTY_FALSE);
end if;
please help figure out what is wrong thank you
for your kind support
|
|
|
Re: search [message #488087 is a reply to message #488086] |
Tue, 04 January 2011 10:57 |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
Describing how it doesn't work would be a good start. What does happen? Do you get an error message?
Why are you setting the displayed property?
Have you read up on the enabled property in form builder help?
|
|
|
|
|
|
Re: search [message #488096 is a reply to message #488094] |
Tue, 04 January 2011 13:15 |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
Then you need to debug the code.
Put messages in before each set of set_item_property statements and see if the code reaches that point.
Also use messages to display the actual value of NAME_GROUP (and you should really prefix that with the datablock name).
|
|
|
|
Re: search [message #488198 is a reply to message #488189] |
Wed, 05 January 2011 10:55 |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
message('name_group is set to '||:NAME_GROUP);
message('name_group is set to '||:NAME_GROUP);
if :NAME_GROUP = 1 THEN
message('branch 1');
message('branch 1');
SET_ITEM-PROPERTY('T1',DISPLAYED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T1',ENABLED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T2',ENABLED,PROPERTY_FALSE);
elsif :NAME_GROUP = 2 THEN
message('branch 2');
message('branch 2');
SET_ITEM-PROPERTY('T1',DISPLAYED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T2',ENABLED,PROPERTY_TRUE);
SET_ITEM-PROPERTY('T1',ENABLED,PROPERTY_FALSE);
end if;
|
|
|
|
|
|
Re: search [message #488221 is a reply to message #488216] |
Wed, 05 January 2011 11:49 |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
So what is name_group set to according to the messgage?
Cause it obviously isn't 1 or 2.
|
|
|
|
|
|
Re: search [message #488228 is a reply to message #488225] |
Wed, 05 January 2011 11:57 |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
If you can't see a value then there is none. name_group is set to null.
What values have you actually assigned to the radio buttons in the radio group?
|
|
|
Re: search [message #488246 is a reply to message #488225] |
Wed, 05 January 2011 13:00 |
joy_division
Messages: 4963 Registered: February 2005 Location: East Coast USA
|
Senior Member |
|
|
Sounds like you are checking the value of the radio group and not the radio button. Buttons have values, not the group.
|
|
|
|
|
|
Re: search [message #488254 is a reply to message #488253] |
Wed, 05 January 2011 17:36 |
cookiemonster
Messages: 13963 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
You know how we're going to tell what that error is?
By calling up form builder help and entering the error number into the search field.
I'm pretty sure you can do that yourself.
|
|
|
|