cancel
Showing results for 
Search instead for 
Did you mean: 

Where to enqueue and dequeue correctly

Former Member
0 Kudos

Dear all,

I have an application in which I need to enqueue tables and dequeue when leavin.

The application consists of one window. In the window I have several views. One main view with a tray to navigate and a ViewContainerUIElement.

When choosing an entry in the tray, a view called "A" is loaded into the ViewContainerUIElement. I now need to enqueue a table A and populate a message in the loaded view if a lock already exists.

If the user then chose another entry of the tray, the existing lock on table A needs to be dequeued before view "B" is loaded into the ViewContainerUIElement and table "B" needs to be locked.

I wanted to implement the enqueue in method WDDOINIT of each corresponding view and the dequeue in the method WDDOEXIT. But WDDOEXIT is not called when I "leave" view A and navigate to view "B" and WDDOINIT of view "B" not called again when navigate to view "B".

Could somebody please give me a hint how to do this? I somehow dont get it done correctly.

Thanks in advance,

Hendrik

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

I am not sure, as I have not implemented, but try to implement it thru exit and resume plugs. May be at this time...wddoexit method of view A and wddoinit method of view B will be called.

Former Member
0 Kudos

Hello Handrick ,

You can create the INBOUND and OUTBOUND plugs for both of view A and B .

And fire these plugs to navigate between the views and write the ENQUEUE and DEQUEUE in side the Inbound plug handler of both the plugs .

For example :

View A :

Inbound plug : A_inbound ( Handler : A_inboundhandler )

Outbound plug : A_outbound

View B:

inbound plug : B_inbound ( Handler : B_inboundhandler)

outbound plug : B_outbound

create a navigation link between A_outbound to B_inbound and B_outbound to A_inbound.

To switch between the view fire the outbound plugs .

in A_inboundhandler : enqueue A records

in B_inboundhandler : enqueue B records

you can dequeue the records while changing the tab or inside the handlers .

you have to write enqueue in the WDDOINIT. it is required for the first time when view is loaded .

I hope this will help you .

Regards

Vivek

Former Member
0 Kudos

Dear all,

thanks for your help and comments.

With the exit plugs I have to check this. I have only one window and switch between the views and think exit plugs are only available to leave a complete window. But thanks for that answer! It gives me an interesting idea on another problem I have and will check this in a sample myself!

The in/outbound plugs are also an interesting idea. The problem I see there is that the user does not necessary need to trigger it. But I think thats a lack in the application design from me. I have one UIContainer in which I load every view I need and on top level the user could still chose a different application component w/o using the functionality that triggeres outbout.

Now, as soon as the user entered into a view where he really maintains data I will make all top level buttongs outside the current view invisible using a mapping to a global context. I like this idea because not useful toolbar etc. do not occupy space on the screen anymore and furthermore your approach Vivek get possible.

So i receive the correct logic by in. and outbound and an even smarter user interface which shows only toolbars and menues where they make sense

So thanks again! I appreciate your help!!

Hendrik

Former Member
0 Kudos

Hello Abap WD,

the longer i think about your short answer the more I begin to understand it. there is quite much behind these few words

I think it will solve most problems I even had doing so because the exit-method is called automatically for that window once I leave it and can release any existing lock and the problem with all the possible triggered actions around my UIContainter get solved.

Just wanted you to know that.

Hendrik

Answers (0)