cancel
Showing results for 
Search instead for 
Did you mean: 

writing code in events of OVS help ?

murali_ram
Participant
0 Kudos

Hi

I have a scenario.  Please look at the picture below.

Here inputbox( companycode)  having OVS search help. next to that are buttons( multiarchive and save).

when i click the ovs search help the two buttons will disable. i need to enable it when i cancel ovs search help.

please help guru's.

Thanks

Murali

Accepted Solutions (1)

Accepted Solutions (1)

amy_king
Active Contributor
0 Kudos

Hi Murali,

I'm not sure it's possible to subscribe to button click events in the OVS window. I don't see mention of this functionality in either NW 7.02 or NW 7.3. Instead maybe you could...

In the ON_OVS event handler method, set a flag in context to indicate the user had opened OVS. Then you could write code in WDDOMODIFYVIEW to enable the buttons if OVS has been opened but the input field is still blank. This would indicate the user had opened OVS but cancelled out before making a selection.

Cheers,

Amy

Answers (4)

Answers (4)

former_member215843
Active Participant
0 Kudos

Hi Murali,

May be the problem cannot be solved with an OVS help, but you can implement your own component, which is used for value help. Then you have more flexibility in your implementation.

http://help.sap.com/saphelp_nw70/helpdata/en/47/9ef8cc9b5e3c5ce10000000a421937/frameset.htm

Regards, Regina

former_member222068
Active Participant
0 Kudos

Hi Murali,

1. Create an attribute 'ENABLE' type 'WDY_BOOLEAN'.

2. Bind the attribute to the button property 'ENABLE'.

3 on action of the cancel buttion, set the value abap_true to enable the buttion.

sample code: lo_el_btn->set_attribute(  name = 'ENABLE  value = abap_true ').

This should solve your requirement.

Note : As mentioned in the requirement, we dont have option of disabling the button, when OVS window popup is displayed, but buttons can be enable as requested.

Thanks & Regards,

Sankar Gelivi

ramakrishnappa
Active Contributor
0 Kudos

Hi Murali,

I appreciate if you could clarify me why you need to enable or disable the buttons when OVS search help window is open.

When OVS search help window is open, no further actions are allowed on main window as popup window of OVS exist. As soon as the OVS window closes, all the buttons/actions are accessible/enabled.

Hope my understanding is correct.

Regards,

Rama

Former Member
0 Kudos

Hi you are correct.

No need to bind to enable/disable.

former_member219762
Contributor
0 Kudos

Hi,

Bind the Enable property of  buttons to context , Subscribe to the event CANCEL  of OVS in your webdynpro component and in that event handler change Enable property as you like.

Regards,

Sreenivas.