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

get transport request type

former_member355261
Participant
0 Likes
1,953

Hello,

I implemented an enhancement to control the description of a transport request when creating it.

So I added my custom code at the and of the form 0100_set_screen in the include LSTR8F01.

I use field symbols to get the value of the fields  KO042-REQ_CONS_K and  KO042-REQ_CUST_W in the program  SAPLSTRH and check which one has the value 'X' to know the TR type (W or K).

Everything works fine when I use the T-Code se10 because this screen always shows up, so I'm able to get the TR type.

But when I use se38 for example to create a program and then I'm asked for a TR number, and when I choose to create one it doesn't work because the previous screen doesn't appear. So I'm not able to get the TR in this case.

So please show me a way to get the TR type in all the situations when creating a TR.

Thanks in advance.

1 ACCEPTED SOLUTION
Read only

guilherme_frisoni
Contributor
0 Likes
1,899

Hi Occoro,

check KO013-TRFUNCTION. Is it available in your enhancement?

Regards,

Frisoni

Hello,

I implemented an enhancement to control the description of a transport request when creating it.

So I added my custom code at the and of the form 0100_set_screen in the include LSTR8F01.

I use field symbols to get the value of the fields  KO042-REQ_CONS_K and  KO042-REQ_CUST_W in the program  SAPLSTRH and check which one has the value 'X' to know the TR type (W or K).

Everything works fine when I use the T-Code se10 because this screen always shows up, so I'm able to get the TR type.

But when I use se38 for example to create a program and then I'm asked for a TR number, and when I choose to create one it doesn't work because the previous screen doesn't appear. So I'm not able to get the TR in this case.

So please show me a way to get the TR type in all the situations when creating a TR.

Thanks in advance.

6 REPLIES 6
Read only

former_member185613
Contributor
0 Likes
1,899

Hi,

Please make use of the BADI CTS_REQUEST_CHECK for controlling the description of a transport request. Its better to go for BADI implementation than implicit enhancement when available.

Hope this helps,

~Athreya

Read only

0 Likes
1,899

Hi,

I was using the BADI CTS_REQUEST_CHECK at the beginning. But I wanted to show a dialog before the one for creation a TR and use it to fill the description field and then gray it out.

So it was impossible to use the BADI to achieve this requirement.

THat's why I'm using the enhancement now.

Read only

rajkumarnarasimman
Active Contributor
0 Likes
1,899

Hi Occoro,

I hope, by default the TR type for the programs(report/module-pool) is going to be Workbench TR. 

Regards

Rajkumar Narasimman

Read only

0 Likes
1,899

Hi Rajkumar,

Yes that's for sure. But I need a way to get it so as I can use it to fill the description field.

Read only

0 Likes
1,899

Hi Occoro,

You can use FM TRINT_GET_REQUEST_TYPE to get the TR type.  Pass the Program details and get the TR type as shown below.

If you have any doubts in TR Export parameters, place a break-point in FM TRINT_GET_REQUEST_TYPE and create a new program in SE38, the cursor will trigger inside the FM TRINT_GET_REQUEST_TYPE in debugger session, from there you can get the Export parameter to be passed.

Hope it works

Regards

Rajkumar Narasimman

Read only

guilherme_frisoni
Contributor
0 Likes
1,900

Hi Occoro,

check KO013-TRFUNCTION. Is it available in your enhancement?

Regards,

Frisoni