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

ALV Output

Former Member
0 Likes
1,158

Hi,

Actualy my report is displaying the field label of domain as the field description in the output. I have the requirement to change description as customised. I am not able to understand where in field catalog it doing for that field. How should i proceed on this.

Regards

Ram

Hi,

Actualy my report is displaying the field label of domain as the field description in the output. I have the requirement to change description as customised. I am not able to understand where in field catalog it doing for that field. How should i proceed on this.

Regards

Ram

10 REPLIES 10
Read only

Former Member
0 Likes
1,118

HI,

U need to fill fieldcatalog ..as.

form get_fieldcat.

DATA: ls_fieldcat TYPE slis_fieldcat_alv.

  • DATA: LS_FIELDCAT TYPE slis_t_fieldcat_alv.

DATA: pos TYPE i VALUE 1.

*DATE

CLEAR ls_fieldcat.

ls_fieldcat-col_pos = pos.

ls_fieldcat-fieldname = 'MATNR'.

ls_fieldcat-datatype = 'CHAR'.

ls_fieldcat-outputlen = 18.

ls_fieldcat-seltext_l = 'Product Number'.

ls_fieldcat-checkbox = 'X'.

APPEND ls_fieldcat TO gt_fieldcat.

CLEAR ls_fieldcat.

*PLANT

pos = pos + 1.

CLEAR ls_fieldcat.

ls_fieldcat-col_pos = pos.

ls_fieldcat-fieldname = 'MAKTX'.

ls_fieldcat-datatype = 'CHAR'.

ls_fieldcat-outputlen = 20.

ls_fieldcat-seltext_l = 'Product Description'.

ls_fieldcat-checkbox = 'X'.

APPEND ls_fieldcat TO gt_fieldcat.

CLEAR ls_fieldcat.

endform.

PERFORM get_fieldcat. "VOC Report

l_title = 'REPORT'.

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

i_grid_title = l_title

i_callback_program = w_repid

it_fieldcat = gt_fieldcat[]

i_save = 'A'

TABLES

t_outtab = gt_final.

ENDFORM. " Show_report

..............................

Regards

CNU

Read only

0 Likes
1,118

In field catalog fill the field reptext_ddic.

Message was edited by:

Alexander Mariadoss

Read only

Former Member
0 Likes
1,118

Hi,

In the field catalog fill up the text in the field reptext_ddic..Which will override the DDIC text..

Thanks,

Naren

Read only

Former Member
0 Likes
1,118

You should explicity pass the description in your field catalogue:

For e.g:

if int_fcat[] is initial.

clear wa_fcat.

wa_fcat-col_pos = 1.

wa_fcat-fieldname = 'CHECKBOX'.

wa_fcat-datatype = 'CHAR'.

wa_fcat-inttype = 'C'.

wa_fcat-intlen = 1.

wa_fcat-seltext_l = 'Check'.

wa_fcat-seltext_m = 'Check'.

wa_fcat-seltext_s = 'Check'.

append wa_fcat to int_fcat.

endif.

Thanks,

Santosh

Read only

Former Member
0 Likes
1,118

Hi,

Do not specify REF_TABNAME and REF_FIELDNAME in the Field Catalog.

Regards,

Vara

Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
1,118

Depending on which ALV tool you are using, the field name can be different.

If you are using the FM, then use field name reptext_ddic in the FC.

If you are using the class, then use the field name REPTEXT in the FC.

Regards,

Rich Heilman

Read only

0 Likes
1,118

Yes, you are correct I am using FM. Can we change the description only for specific fields.

Thanks

Ram

Read only

0 Likes
1,118

Yes, for certain columns, when building the feildcat, simple fill the reptext_ddic field .

fc_tmp-reptext_ddic  =  'This description'.

Regards,

Rich Heilman

Read only

Former Member
0 Likes
1,118

Hi Shri,

In the slis_fieldcat_main0 structure there is field called <u><i>ddictxt(1)</i></u> which is going to get text from the dictionary.

If you comment that and add the other field like <i><b>seltext_l , seltext_m, seltext_s</b></i> {Any one} to add your own text.

reward if it helps.

Thanks

KER

Read only

Former Member
0 Likes
1,118

Hi,

Yes..You can replace the text using the field reptext_ddic in the field catalog.

s_fieldcatalog-reptext_ddic = 'My Text'.

Thanks,

Naren