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

ABAP for displaying message using performance assistant

Former Member
0 Likes
2,854

I want to display the long form of a custom message using the performance assistant.

The following code successfully displays the long form of the message, but in the old style (before the performance assistant).

CALL FUNCTION 'HELP_OBJECT_SHOW'

EXPORTING

DOKCLASS = 'NA'

DOKLANGU = SY-LANGU

DOKNAME = 'ZINTERFACES001'

  • DOKTITLE = ' '

CALLED_BY_PROGRAM = sy-cprog

CALLED_BY_DYNP = sy-dynnr

  • CALLED_FOR_TAB = ' '

  • CALLED_FOR_FIELD = ' '

  • CALLED_FOR_TAB_FLD_BTCH_INPUT = ' '

MSG_VAR_1 = 'ABC'

MSG_VAR_2 = ' '

MSG_VAR_3 = ' '

MSG_VAR_4 = ' '

  • CALLED_BY_CUAPROG = ' '

  • CALLED_BY_CUASTAT =

  • SHORT_TEXT = ' '

CLASSIC_SAPSCRIPT = 'X'

TABLES

LINKS = links

EXCEPTIONS

OBJECT_NOT_FOUND = 1

SAPSCRIPT_ERROR = 2

OTHERS = 3.

That is because we have CLASSIC_SAPSCRIPT = 'X' ("not in the performance assistant").

However when we have CLASSIC_SAPSCRIPT = ' ', then nothing is displayed.

Help please!

John

5 REPLIES 5
Read only

Former Member
0 Likes
1,564

ex---

You can find out the identifier of the help text (F1 help) defined for a field in the ABAP Dictionary using the HELP-ID addition:

DESCRIBE FIELD <f> HELP-ID <h>.

If the field <f> is defined with reference to a data type from the ABAP Dictionary, the statement writes the help text ID into the variable <h>. You can use the ID in a suitable function module to display the help text.

DATA: company TYPE s_carr_id,

h(20) TYPE c,

tlink TYPE TABLE OF tline.

DESCRIBE FIELD company HELP-ID h.

CALL FUNCTION 'HELP_OBJECT_SHOW'

EXPORTING

dokclass = 'DE'

doklangu = sy-langu

dokname = h

TABLES

links = tlink

EXCEPTIONS

object_not_found = 1

sapscript_error = 2

others = 3.

IF sy-subrc <> 0.

...

ENDIF.

In this program, the field H receives the name of the data element S_CARR_ID. The function module HELP_OBJECT_SHOW displays the documentation for the data element in a dialog box.

Reward all the helpful answers.

Thanks

Murali Poli

Read only

Former Member
0 Likes
1,564

Hi,

You can try with the function module HELP_OBJECT_SHOW_FOR_FIELD

Regards

Sudheer

Read only

Former Member
0 Likes
1,564

Thanks, but I am not wanting to show the help for a field.

I am wanting to show the long-text version of a message defined in SE91.

John

Read only

Former Member
0 Likes
1,564

In case it is a clue to my problem:

the code given by Murali Poli does not work for me.

John

Read only

0 Likes
1,564

Try function module HELP_START