cancel
Showing results for 
Search instead for 
Did you mean: 

Set Default Button

Murali_Shanmu
Active Contributor
0 Kudos

Hi,

I have 3 buttons in a Transparent Container. How do i make one the default button.There is a property called defaultButtonId for the Container. Would this be of Help ?

Regards,

Murali.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Murali,

Why dont you use the defaultButtonId property of Transparent Container and try out?

Regards,

<i><b>Raja Sekhar</b></i>

Murali_Shanmu
Active Contributor
0 Kudos

Plz do then, let me know how to use this property.

Regards,

Murali.

thomas_szcs
Active Contributor
0 Kudos

Hi Murali,

You need to put in the ID of the button that is supposed to be default button inside of the container hierarchy of this container. There's a dropdown at this property to assist you.

Best regards,

Thomas

Murali_Shanmu
Active Contributor
0 Kudos

Thanks for the reply Thomas. I tried it, but I didnt see any effect.

Regards,

Mruali

thomas_szcs
Active Contributor
0 Kudos

Hi Murali,

Do you have an input field or some other focus receivable ui element inside of the transparent container? If so, if you place the cursor inside and press enter, will a roundtrip be triggered?

Best regards,

Thomas

Murali_Shanmu
Active Contributor
0 Kudos

Hi Thomas,

How can i bring focus to an Input field. The property mentioned is defaultButtonId. I just have a transparent container with 3 buttons. I gave a particular button id as value to the proprty of defaultButtonId of the Transparent container. I am not able to see any focus being set at all. Have you tried this before.

Regards,

Murali.

SergioFerrari
Active Contributor
0 Kudos

Hi Murali, to me it's not clear to me if you are trying to get the focus on an InputField or on a Button (as stated in the first message of your post).

Sergio

Murali_Shanmu
Active Contributor
0 Kudos

Hi Sergio,

I am trying to set focus to a button in a Container. Generally in AbstractPortalComponent/JSPDynpage/HTMLB we have the option to make one buton on the screen as the default button. So whenever the user hits the Enter key, the action attached to that button is fired. I am just trying to simulate this in WDA.

Regards

Murali.

SergioFerrari
Active Contributor
0 Kudos

As Thomas said : "If so, if you place the cursor inside and press enter, will a roundtrip be triggered?"

What you can do is:

- define a default button for a transparent container

- run the application

- click in the transparent container area (it is transparent but you should know where it is and how big it is)

- you will see that the default button will be focused

- press the space bar

Maybe it is not exactly what you are looking for but it is how it works,

Sergio

Murali_Shanmu
Active Contributor
0 Kudos

Hi Sergio,

Thanks for making me understand what Thomas was trying to explain me.

Thomas, Thanks a lot.

Regards,

Murali.

Answers (0)