I am working with CATT, and the transactions are <b>ME21N</b> and <b>MIGO</b>.
when i am executing the transaction <b>ME21N</b> i will get the <b>Pur Ord No</b>in the message, and i would like to export <b>Pur Ord No</b> to the transaction <b>MIGO</b> as thr is one field named Purch.ord no in Migo.
what should be the Procedure for exporting a parameter?
If you are using eCATT then following is the procedure of capturing messages in the two recording methods - TCD & SAPGUI.
=> TCD Recording Mode:
In TCD recording mode, after dobleclicking on Interface name from the TCD command in the editor on left side, just before the MSG folder DYNPRO folder will appear on right side.
-This DYNRPO folder contains the screen sequences contain the screen occurred during recording time. The last Dynpro of this folder contains the messages occurred during recording.
-Select this last folder & click on Simulate Screen icon of the same Interface editor. It will redirect to the screen where the message values exist. There select the Purchase Order Number and click on Read Field Value icon. Give the name of Export Variable.
The export variable will contain the value of the purchase order number, which can be passed to MIGO.
=> SAPGUI Recording Mode:
In the SAPGUI recording mode, the screen on which the message appeared will be used to capture the variable name, which is Purchase Order Number in this case.
If the Purchase Order Number is second variable of the message displayed(e.g. Purchase Number 2122323 Is Created)
then use the following code -
MESSAGE ( MSG_1 ).
SAPGUI ( ME21N_4001_STEP_5 ).
ENDMESSAGE ( E_MSG_1 ).
Assing the value from the message to the export
P_EC_PurOrdNo = E_MSG_1--MSGV2.
There are total four MSGV1-MSGV4 variables. Dobule click on MSG_1 of the MESSAGE statement above. Putting the value in the export variable from the right message variable will give the purchase order number.This can be passed as MIGO.