Application Development and Automation 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: 
Read only

How do I create a t-code to call another t-code with no params or variants?

Former Member
0 Likes
1,996

Good day!

This one should be easy, but I've been wrestling with it all afternoon and am stuck. My customer has asked me to create t-codes for a list of different SPRO activities. One of the activities has a t-code of OFMCA_P001. Yes, I could just tell the customer to use this t-code to get to the SPRO activity directly, but the purpose is to come up with some more English-friendly t-codes that reflect the activity. In this case, I want to call my new t-code Z_DEFINE_RE_ACCTS.

I've tried to go to SE93 and create a new transaction with variant, which doesn't work because I want to leave the variant field blank and the system won't accept that. I then tried creating a new transaction with parameters, leaving out the parameters, but this causing a short dump.

I brought up OFMCA_P001 in SE93, and I thought about just cloning it to the new name, but I'm wary of doing that if SAP should change something about the original OFMCA_P001 t-code in the future. I'd rather my t-code call the SAP one so that I won't get tripped up on any future changes.

Is there a way to do this, or is cloning it my only option?

Thanks so much! Points awarded to all helpful answers.

Dave

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,831

this transaction OFMCA_P001 is not a dialog one, so i am not sure how you can use that.

But for normal one, I would say to create a transaction variant using SHD0 dont do anything in the there, and leave everything as is, and then define the trsantion for the variant.

Other option would be to create a z report with a one line code - call trsnaction OFMCA_P001. then you can assign a tcode to that report

this transaction OFMCA_P001 is not a dialog one, so i am not sure how you can use that.

But for normal one, I would say to create a transaction variant using SHD0 dont do anything in the there, and leave everything as is, and then define the trsantion for the variant.

Other option would be to create a z report with a one line code - call trsnaction OFMCA_P001. then you can assign a tcode to that report

6 REPLIES 6
Read only

Former Member
0 Likes
1,832

this transaction OFMCA_P001 is not a dialog one, so i am not sure how you can use that.

But for normal one, I would say to create a transaction variant using SHD0 dont do anything in the there, and leave everything as is, and then define the trsantion for the variant.

Other option would be to create a z report with a one line code - call trsnaction OFMCA_P001. then you can assign a tcode to that report

Read only

0 Likes
1,831

MxG, I don't know why I didn't think of just creating a simple, one-line program to call the transaction. I think that will definitely solve my issue. Thanks much -- full points awarded!

Read only

Former Member
0 Likes
1,831

Hi,

GO to se93...copy (SHIFT + F1) the transaction code OFMCA_P001 and give it a new name Z_DEFINE_RE_ACCTS..

Thanks

Naren

Read only

Former Member
0 Likes
1,831

Question answered.

Read only

Former Member
0 Likes
1,831

Question answered.

Read only

Former Member
0 Likes
1,831

Hi,

I don't think a new program is required...just copy the existing standard sap tcode to create a new z one..

Thanks

Naren