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

To Change Parameter Labels in Selection Screen At Runtime

Hi All,

I had a need to change the parameter labels which were like p_bukrs, p_ktogr and p_file to Company Code, Acct Determination ans Upload File respectively.

I found a solution which I thought would be worthwhile to share.

In the INITIALIZATION event,

please proceed as follows:

DATA: cocd LIKE tabfield-lfieldname,

acc_det LIKE tabfield-lfieldname,

filename LIKE tabfield-lfieldname.

cocd = 'T001-BUKRS'.

acc_det = 'T095A-KTOGR'

filename = 'rlgrap-filename'(001).

PARAMETERS: p_bukrs LIKE (cocd),

p_ktogr LIKE (acdec),

p_file LIKE (filename).

Let us dissect p_bukrs LIKE (cocd).

This makes the name of the reference field p_bukrs be specified as the contents of field 'cocd' at runtime.

Parameter p_bukrs will appear on the SELECTION SCREEN with the Technical Attributes of T001-BUKRS. The Text of p_bukrs will be taken from the text of T001-BUKRS from the ABAP dictionary.

Now, considering filename = 'rlgrap-filename'(001).

We have provided 'filename' with a SELECTION TEXT.

Hence the system will display that text only on the SELECTION SCREEN, even if it is a database field.

Note: The parameters will always be created as character strings with length 132.

Reward If This was found to be of help!

Edited by: prosenjit chaudhuri on Jan 29, 2008 11:42 AM

Edited by: prosenjit chaudhuri on Jan 30, 2008 7:38 AM

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Jan 29, 2008 at 10:47 AM

    in the prg

    goto > text elements ->selection texts.

    in selection texts u can type as u like

    that text will appear in ur selection screen

    Madhavi

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Madhavi,

      You are absolutely right. However, in this alternative F1 and F4 helps can be inherited into the parameter field from the database fields. This cannot be done by Selection Texts only.

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.