Skip to Content
-2

Pass Parameter to a an already opened transaction using call transaction from ALV Report.

May 02, 2017 at 03:47 PM

183

avatar image

Hi ,

I have developed a report which will take values from 'VA01' tcode using 'SET PARAMETER ID' and creates a report.

Now when the user double clicks on any line of the ALV report,the values from that line should be passed to the same va01 transaction.

Basically my report will have material numbers and that double clicked material number should be made available to the Item overview tab of VA01.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

4 Answers

Best Answer
Richard Harper May 08, 2017 at 12:40 PM
1

Thanks to @Moshe Naveh who found this question for me....

User exit USEREXIT_CUST_MATERIAL_READ in MV45AFZB is triggered when the material number changes. You can do a call screen in there to a custom screen where you can insert your own code including the ALV. I have used this technique to populate fields in the item tab myself.

Sorry in the delay but I couldn't find this again.....

Rich

Share
10 |10000 characters needed characters left characters exceeded
Divya Venkatakrishnan May 02, 2017 at 04:30 PM
-3

To explain better.

My scenario is - In va01 transaction when i create an order

  • 1)I enter material/item in the item overview tab.
  • 2)I go to the Deals over ride column and press F4, this shows me the deals that are available for the selected item (custom).
  • 3)Then I open a ztcode and that opens up an ALV with list of items that qualifies the deal (custom)
  • 4)Now When I double click on any line of the item that is double clicked , it should be placed in va01 item overview tab in the next line.-- How will i achieve this??

Thanks,

Share
10 |10000 characters needed characters left characters exceeded
Mangesh Parihar May 03, 2017 at 05:08 AM
0

Hi,

Have you tried call transaction statement?

CALL TRANSACTION 'VA01' AND SKIP FIRST SCREEN.

You can find example code in sap archives.

Regards,

Mangesh Parihar

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Yes i am already using the 'Call transaction va01 ' , But i would like to go to the already opened va01 and update that with the double clicked values from ALV

0
Sandra Rossi May 03, 2017 at 09:13 AM
0

Use the "batch input" capability of CALL TRANSACTION ... USING bdcdata.

This way you can fill screen fields and navigate between screens automatically.

Please refer to the ABAP documentation for more information + SCN forum archived threads.

Show 6 Share
10 |10000 characters needed characters left characters exceeded

Hi Sandra ,

My scenario is i am in va01 tcode already and with 1) custom development pop up screen , i click in the green okay button 2) my custom alv with the materials in the va01 screen , along with other materials which falls under the same category opens up (in new session).

At this point my va01 is still open and my custom alv is open in another session.

Now when i double click a line in the alv it should update the already opened va01 with the double clicked line's value.

By using 'Call Transaction Va01 , it just opens a new order entry screen.

0
Divya Venkatakrishnan
Thanks for clarifying. If at least this kind of feature could exist somewhere, we could reproduce the same coding, but unfortunately it doesn't. You or the client should adapt the requirement to what is feasible with this old dynpro technology.
0

So just to clarify that my understanding is right, we cannot dynamically populate or append value (add line items) to the va01 screen with data from a table or report by double clicking?

Thanks,

I have been breaking my head , with submit program exporting list from memory and all..

0
Divya Venkatakrishnan
Yes, it's not feasible the way you wish to do it. You should do it completely differently and in a simple way, by respecting the technology limits. If you did extensive tests of all things possible, now you should be able to tell the client what is feasible.
1

Hi Sandra /Richard, Thanks.

Yes this is my POC of whether and how my logic will work.

So now what i have achieved is , in the user exit i am having a pop up screen which will be invoked when one of the columns in the item overview tab is clicked(F4). --> No issues , this works fine.

Next i use this FM 'ABAP4_CALL_TRANSACTION' to call my alv( which is attached to the tcode) with the parameters in the va01 screen.

Works perfect.

I have to accept the fact that clicking on any line in alv will not place the contents in my va01 item lines.

Thanks again.

0

There is a user exit that is called when the material number changes in the line items display in VA01/2 which will be a better bet. I know it exists because I have used it before, and for the life of me now I can't find it. However, that would be a better bet than anything above I think. Unfortunately though I'm at work and running short of time, but that is the direction I would go in.

If I have chance tonight I will look on my own laptop.

Rich

1