Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

update ALV-grid from results of parallel processing

guenter_schepers
Explorer
0 Kudos
308

Hi,

i am facing the following Problem: I have an application which selects, displays and edit data in several ALV-grids (dynpo with custom Container). Due to the amount of data we split up the whole process of selection into a "main" and one parallel process. The "main" process selects only a part of the data and displays them quickly.  From this time on the user can work within the "cockpit" and edit/ Change data, start other Transactions and so on. Parallel the second process selects all needed data. And now the Problem begins. I want to update the displayed ALV-grids with the selected data from the parallel process, but i find no way to "tell" the dynpro that new data arrived and the grid should be refreshed. In the receiving module of the parallel process all commands influencing the dynpro logic or even the Screen are forbidden. Triggering an event    (user command) shows the same result. AND using a time Trigger to check frequently if data has been changed doesn't work too as the timer takes over the control of the dynpro for the time of working which leads to confusion at the users when they are editing/ changing data in that Moment.

Did anyone faced the same or similiar Situation and found a solution or does anyone have an idea what might solve my Problem?

Thx

Günter

1 ACCEPTED SOLUTION

Sandra_Rossi
Active Contributor
0 Kudos
134

The only solution to refresh the data is to use aRFC or CL_GUI_TIMER.

It doesn't surprise me that there's an issue with the focus if the user enters data in a first ALV at the same time a second ALV is refreshed.

But unfortunately, you don't explain exactly what the "confusion" is about. Could you explain?

Did you try to restore the focus to the first ALV, with CL_GUI_CONTROL=>SET_FOCUS method, to minimize a little bit the bad side effects?

8 REPLIES 8

Sandra_Rossi
Active Contributor
0 Kudos
135

The only solution to refresh the data is to use aRFC or CL_GUI_TIMER.

It doesn't surprise me that there's an issue with the focus if the user enters data in a first ALV at the same time a second ALV is refreshed.

But unfortunately, you don't explain exactly what the "confusion" is about. Could you explain?

Did you try to restore the focus to the first ALV, with CL_GUI_CONTROL=>SET_FOCUS method, to minimize a little bit the bad side effects?

0 Kudos
134

Hi Sandra,

you saved my day It was my fault as i was always refreshing the Screen and not only once when the parallel process is finished.

To your question: in my application there are more than 2 ALV-grids and the users were confused when say each second the Focus Switches or when you are in an entry field, the just entered characters are gone.

But now - with my knowledge - the Screen is only updated once which will be ok for the users.

Kind regards

Günter

0 Kudos
134

Thanks, good to know. You should mark your answer as the solution to close the thread.

former_member182550
Active Contributor
0 Kudos
134

The parallel process (if it is a true parallel process) has a parameter 'PERFORMING XXX AT END OF TASK'.

In the procedure that you specify you 'RECEIVE' your results back into your main program,  update your global data tables and call the refresh methods for your ALV's.

Rich

0 Kudos
134

Hi Rich,

that's exactly what is NOT working - refreshing the ALV from within the receive module. Even raising an Event which should refresh the ALV didn't work.


Günter

0 Kudos
134

That'll teach me to answer questions whilst still asleep.....

Rich

0 Kudos
134

Hi Rich,

if i annoyed you with my answer i have to say sorry  - that was not my Intention. I just wanted to clarify what my Problem was and i thought that i didn't made i clear enough.

Please don't be angry and Keep on answering all Kind of questions

take care

Günter

0 Kudos
134

Oh Gunter!!!

I was not annoyed,  I was taking the mickey out of myself at not reading your question!!  Thank you for the apology though.

Rich