cancel
Showing results for 
Search instead for 
Did you mean: 

Trigger a event in the WDA from ABAP

Former Member
0 Kudos

Hello Guys,

I need trigger a event in the WDA from a Z * transaction from ABAP.

How I can do this?

Thank you.

Best regards,

Bruno

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member184578
Active Contributor
0 Kudos

Hi.,

Place the code of event in a Function module or method of a class and call that Function module or method.,

Thanks & regards,

Kiran

Former Member
0 Kudos

Hello Kiran,

What I am doing is the following:

1 - Within the WDA component

2 - The user clicks a button

3 - This button calls a Z transaction in a pop-up

4 - The user clicks save

5 - The WDA closes the pop-up get the parameters and back to the home screen.

My problem is in step 5. I thought in trigger an event the WDA through the ABAP code, but not know if I can and not find any source to show me the path.

Thanks,

Bruno

Former Member
0 Kudos

Hi,

I am afraid that your step-5 is not realizable as you wish. You do not have a facility to subscribe to a event other than WDA components.

Your best option is to go for a Server side cookie. When you leave the transaction, write the intended data to the server cookie and read it back from WebDynpro on close of the window.

Former Member
0 Kudos

Ok, But what idea can you give me to know that the user clicked to save and what should I close the pop-up?

Thank you.

Bruno

Former Member
0 Kudos

Just before opening the popup , you can save the popup instance in a attribute of type if_wd_window and use the method SET_ON_CLOSE_ACTION to subscribe to close event.

In the event handler you can call the function module/Server cookie to see if you have data. In the data string save a attribute to conclude save/cancel actions.