‎2004 Sep 08 11:06 PM
Hi,
I want to call a transaction and the pass the paramter with the values. There are three paramters in the Transaction screen AGR,WRK,AAT. I want to pass the value from my program to the transaction.
DATA: l_WORKCENTER LIKE CRHD-ARBPL VALUE '10984A3',
l_PLANT LIKE CRHD-WERKS VALUE 'ECES',
l_ORDERTYPE LIKE CYAUKO-AUART VALUE 'G080'.
SET PARAMETER ID 'AGR' FIELD l_WORKCENTER.
SET PARAMETER ID 'WRK' FIELD l_PLANT.
SET PARAMETER ID 'AAT' FIELD l_ORDERTYPE.
CALL TRANSACTION 'CM24'.
Is this the correct way? It didn't work.
Problem is the third parameter 'AAT' doesn't get populated in the screen. The screen development is not in my hand.
How to check that whether the paramter is set for that text field? so that i can suggest the CM24 screen Developer. I think he didn't get the paramter for that input field.
I hope you guys have CM24 in your system?
Thank you
arun
Message was edited by: Arun Prasad
‎2004 Sep 08 11:11 PM
To check if the fields are being populated correctly, remove the 'SKIP FIRST SCREEN'. Also I presume the following line
DATA: l_WORKCENTER LIKE CRHD-ARBPL '1087456',
should be
DATA: l_WORKCENTER LIKE CRHD-ARBPL VALUE '1087456',
‎2004 Sep 08 11:14 PM
Hi,
The logic and the syntax seem to be true except the first line. It should be
DATA: l_WORKCENTER LIKE CRHD-ARBPL <b>VALUE</b> '1087456',
But I guess the problem is not this. So what problem do you encounter?
*--Serdar
‎2004 Sep 09 12:06 AM
Hi Arun
While you are at the first screen of "CM24" and the cursor is on the field to which "i_ordertype" will be passed, press F1 and then F9 (if you use performance assistant press the button with hammer and monkeywrench after pressing F1). In the popup screen there should be a box where the parameter ID is written. Check whether it is the same as yours ('AAT').
Hope they are not the same.
It's now bed time here... Hope you can handle it anyway...
*--Serdar
‎2004 Sep 09 3:35 PM
Hi Arun,
Since CM24 is a report-transaction you may try
Submit RCCRY000 with parameters (use Pattern, other Pattern, SUBMIT)
‎2004 Sep 09 3:44 PM
Hi Arun,
I don't see ordertype in 4.7 system transaction CM24. What system are you on right now?
‎2004 Sep 09 5:24 PM
Hi serder,
I am working on 47.
I found this parameterID from F1 help. The three parameter IDs are exactly the same AGR,WRK,AAT. The values are passed to the other two. But for the third one the value is not passed.
I want to understand about parameter ID, Is that the same Parameter ID set for the InputBox in the screen or it is been explicitly defined.
Because the other developer would have not assigned the parameter to the Inputbox.
How do i find this ParameterID definition?
one more doubt, In that screen There are two inputbox for each selection from value and to value which are named something like AFKAUART-LOW and AFKAUART-HIGH, Both of them has the same ParameterID. This really confuses me. I though One ParameterID is assigned to only one inputbox.If it is assigned to more inputboxes then all of them should get the value. Can someone clear this doubt?
Thank you
arun
‎2004 Sep 09 8:22 PM
I did not find AAT parameter id in CM24 in 4.7. Anyway sometimes you cannot rely on the parameter id obtained from F1. In some cases (e.g. sales document transactions) SAP uses tricky parameter id evaluation in PBO logic. So, you might want to take a look into source code of the transaction. Maybe it would be clarified.
‎2004 Sep 09 8:47 PM
Hi Arun,
Parameter ids in txn CM24 is defined in the reference field of the select-options field. For example, Work Center use data element of field ARBPL of table CRHD because the screen select-options field refer to CRHD-ARBPL. So the selection field has parameter id AGR just like in DDIC field CRHD-ARBPL refered to. To look at parameter id list, do SM30 on table TPARA.
‎2004 Sep 09 10:08 PM
Hi Arun
I think, as Viktor has recommended, submitting the report seems as a proper solution.
e.g.
From the selection screen, after finding out what <par1>, <par2>, and <par3> are:
<b>SUBMIT RCCRY000
WITH <par1> EQ l_WORKCENTER
WITH <par2> EQ l_PLANT
WITH <par3> EQ l_ORDERTYPE .</b>
However, if you still want to use call transaction method, try to find proper parameter IDs as Nablan explained. As previous contributors told, I couldn't figure out any parameters on the screen having parameter ID 'AAT', either.
There were ;
AGR --> Work Center
WRK --> Plant
CAA --> Capacity category
CAP --> individual capacity
PER --> Personel number
Otherwise, your syntax and logic of transaction call is correct.
*--Serdar
‎2004 Sep 09 10:30 PM
Hi,
Thanks guys anyhow this is the problem with the CM24 screen.
Anyhow i need to use Call Transaction. Because i want to call this transaction inside an workflow method. I want this screen to be pre-populated and once i call the workflow method. But right now i am checking it from an SE38 program stub.
I want to know any other way to find out the paramter assigned to a field. Should i go into the screen level PBO/PAI logic.
Is that recommended? or any other way
Thank you
arun
Message was edited by: Arun Prasad
‎2004 Sep 10 4:30 PM
If you want to know what parameter ids currently used by a transaction, run that transaction in debugging mode. Then click on pulldown Goto->System Area->SAP Memory. You will see what parameter ids are used at that moment.
‎2004 Sep 10 8:49 PM
Hi,
After setting the parameters , why not trying getting the parameters (Only for testing ), if really your parameters are being loaded properly or not
Rajiv
‎2004 Sep 14 6:13 PM
Hi Arun,
It is not necessary that you use only call transaction for workflow. It is perfectly alright to use Submit report. Will the task be called in foreground or background?
Cheers,
Ramki.