Home » Developer & Programmer » Forms » Problem facing in when-radio-changed (forms 10g)
Problem facing in when-radio-changed [message #438634] Mon, 11 January 2010 05:32 Go to next message
sandip109
Messages: 5
Registered: January 2010
Location: India
Junior Member

Hi all, I am working on forms 10g.
I have a radio group item and another is a text item.
When i select redio button YES then that text item should enable and also value required .

If it is NO the disable and value not required .

I have written on WHEN-RADIO-CHANGED

IF :T_ITEM_LAPTOP.CONNECT_TO_NETWORK = 'Y' THEN

Set_Item_Property('T_ITEM_LAPTOP.IP_ADDRESS',enabled,property_true);

Set_Item_Property('T_ITEM_LAPTOP.IP_ADDRESS',required,property_true);

else

Set_Item_Property('T_ITEM_LAPTOP.IP_ADDRESS',enabled,property_false);

Set_Item_Property('T_ITEM_LAPTOP.IP_ADDRESS',required,property_false);

end if;


But only one triger is working (enabled property ). Another is not working .
So what should i do ?
Re: Problem facing in when-radio-changed [message #438635 is a reply to message #438634] Mon, 11 January 2010 05:46 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
What exactly is not working? What do you expect to happen?
Re: Problem facing in when-radio-changed [message #438650 is a reply to message #438635] Mon, 11 January 2010 07:12 Go to previous messageGo to next message
bad_sector007
Messages: 12
Registered: December 2009
Location: Egypt
Junior Member

Hello
I just want to check with you something in the code
You said
When i select redio button YES then that text item should enable and also value required .

If it is NO the disable and value not required .

you here said Yes - No

and in the code you said ( Y - else)
IF :T_ITEM_LAPTOP.CONNECT_TO_NETWORK = 'Y' THEN --- else

I think you should make it all Y or Yes.

* I've created a simple form in the attached files based on hr/hr and your if statment.

Respectfully
Khaled Farouk
  • Attachment: hr2.fmb
    (Size: 56.00KB, Downloaded 1076 times)
Re: Problem facing in when-radio-changed [message #438734 is a reply to message #438634] Tue, 12 January 2010 00:12 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Please read the documentation or Forms Builder Help for an explanation of the OTHER attributes that have to be set 'on' when 'enable' has been set 'on'.

David
Previous Topic: Call a report from menu item (merged 2)
Next Topic: Moving Text in a display filed
Goto Forum:
  


Current Time: Fri Sep 20 12:35:32 CDT 2024