cancel
Showing results for 
Search instead for 
Did you mean: 

Trigger T-Code Synchronously from WD4A

Former Member
0 Kudos

Hi All,

I have a requirment in which I have to trigger a transaction code from WD4A view synchronously.

After the transaction code is opened in another window the WD4A component should continue to listen if the transaction code window is closed.

e.g.. when a confirmation pop-up window is displayed in WD4A the control is gained by the pop-up window and user cannot perform any action on the parent or main window. And when the pop-up closes the parent window gets to know this. The parent view is again rendered.

In a similar way i have to trigger a transaction from WD4A.

The parent View/Window should be inactive till the transactional window is open and the parent window/view should listen when the transaction window is closed.

Please let me know how this can be done.

Can this be achieved by transactional i-View or any other method.

Regards,

Sameer.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Sameer,

Thomas is right - I think always right :-).

However you might want to consider not holding both sessions (WDA and GUI) open.

You have not supplied enough detail but this concept may work.

1. You could launch a GUI (HTML or Windows) from your WDA.

If you want to do the Windows version, then you can attach a shortcut file to the frontend (ie like a PDF or pic file). Depending on SSO, Windows File Types (.sap), browser setting etc you can get the Windows GUI to open on the transaction you want. We have done this.

2. Then close the WDA window after opening the transaction (Exit Plug).

3. On closing the transaction, trigger the WDA again (maybe an exit on save or a wrapper for the transaction).

Saying all that, without further info, you might be needing to pass parameters into the WDA to manage the flow.

In addition; if searching etc was used up front, you may be needing to save these off before calling the transaction, then using them on the way back.

All this depends on how keen you are to manage this.

Personally, I would stick with Thomas's answer.

JS

thomas_jung
Developer Advocate
Developer Advocate
0 Kudos

>After the transaction code is opened in another window the WD4A component should continue to listen if the transaction code window is closed.

I can already tell you that what you describe is not technically possible. The Web Dynpro Application can call to the SAPGUI for HTML and hope it via the browers in a new window - but then there are two user sessions. The two application instances are no longer linked in any way.

>And when the pop-up closes the parent window gets to know this. The parent view is again rendered.

That's because the popup is just a floating iFrame within the same browser window. Its a trick of JavaScript and HTML; there isn't actually a modal window (no separate browser window or HTTP session).