Skip to Content
author's profile photo Former Member
Former Member

Provide Input Parameters when called only from a TCODE

Hi Experts,

I have a requirement where in we need to provide a input parameters for a report when it is triggered from a TCODE.

When this program is executed in SE38, the input parameters should not be available. The report takes a default value which is

defined in the program.

We need use the same program when called using the TCODE, as well as from SE38.

Looking for a early response.

Thanks in advance.

Regards,

Kumar.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

6 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Oct 11, 2010 at 09:05 AM

    Suhas Saha,

    The program willl be scheduled everyday which will take the default date.

    For retriving data for a particular date i need to provide user input screen. This will be done through ZTCODE.

    Regards,

    Kumar.

    Add a comment
    10|10000 characters needed characters exceeded

    • >

      > The program willl be scheduled everyday which will take the default date.

      In case of Background processing SELECTION-SCREEN will not be displayed so you don't have to worry about it.

      For retriving data for a particular date i need to provide user input screen. This will be done through ZTCODE.

      You would schedule the job on a daily basis in SM36 & for individual dates you'll access the report via the T-Code. So where does SE38 come into the picture?

      @Marcin: If SY-BATCH = 'X', i don't think SELECTION-SCREEN will be available 😊

      BR,

      SUhas

  • Posted on Oct 10, 2010 at 09:47 AM

    You can use [Parameter Transaction|http://help.sap.com/saphelp_nw04/helpdata/en/eb/5fab44d79b11d296190000e82de14a/frameset.htm] in order to pass data to the report once called by this tcode.

    Regards

    Marcin

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 10, 2010 at 12:13 PM

    Use event INITIALIZATION.

    And check if sy-tcode <> 'SA38' and <> 'SE38'.

    Then set the value for the parameter.

    Regards

    Roy

    Edited by: Roy Olav Johansen on Oct 10, 2010 2:14 PM

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 11, 2010 at 05:35 AM

    Thanks for your response.

    But the requirement is, the parameter screen itself should not available if i trigger the code from SE38.

    And the parameter screen should be available if i come through the TCODE.

    Regards,

    Kumar

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 11, 2010 at 08:39 AM

    Dear Marcin,

    Thanks for ur comment.

    If i do as suggested by you,

    Screen parameters are inactive, this is ok, but it stops at a empty screen.

    I need to press the execute button again to run the program. This is should not happen. The program should run without any manual interventions or any error message popping out if run through SE38. If i run from TCODE it should show the input parameters.

    Regards,

    Kumar

    Add a comment
    10|10000 characters needed characters exceeded

    • >

      > I need to press the execute button again to run the program. This is should not happen. The program should run without any manual interventions or any error message popping out if run through SE38. If i run from TCODE it should show the input parameters.

      I don't get why do you want this functionality. Do your users have authority for SE38 in Production?

  • author's profile photo Former Member
    Former Member
    Posted on Oct 11, 2010 at 10:03 AM

    Hi all,

    Thanks for the response.

    Got the Solution.

    Regards,

    Kumar.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.