cancel
Showing results for 
Search instead for 
Did you mean: 

How to control display of a checkbox

Former Member
0 Kudos

Hello Experts,

I have an HTMLB form. It has a DropdownlistBox. My requirement is to display a checkbox only when certain value is selected from the dropdown. I tried to use the property 'OnClientSelect' by calling a javascript function, but somehow things are

not working.

Please provide your inputs as to how can i do this? Or a piece of code that you may want to share.

I need to do this at the earliest. Awaiting your responses.

Thanks a ton for time and help!

Regards,

Anupama

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

what about wrapping the checkbox into a DIV with given ID. Then in onClientSelect call a JS which hides/shows the DIV element.

Romano

Answers (2)

Answers (2)

Former Member
0 Kudos

>

> Hello Experts,

>

>

> I have an HTMLB form. It has a DropdownlistBox. My requirement is to display a checkbox only when certain value is selected from the dropdown. I tried to use the property 'OnClientSelect' by calling a javascript function, but somehow things are

> not working.

>

> Please provide your inputs as to how can i do this? Or a piece of code that you may want to share.

>

> I need to do this at the earliest. Awaiting your responses.

>

> Thanks a ton for time and help!

>

>

> Regards,

> Anupama

Hi Anupama,

Your approach with using OnClientSelect is correct, because I think you want to avoid an unnecessary additional server request cycle just to display a checkbox (which would be the case when using OnSelect).

Maybe you could show us some releveant code? I can just guess now what the error may be Maybe you have e.g. forgotten to set the jsObjectNeeded property of the checkbox, etc.

Former Member
0 Kudos

Hi Anupama,

Instead of using OnClientSelect use OnSelect. OnClientSelect will not trigger any server event.

You would also like to check: http://help.sap.com/saphelp_nw04/helpdata/en/09/9c0e41a346ef6fe10000000a1550b0/content.htm

Hope this helps.

Regards,

Vaibhav