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

field catalog

SG141
Active Participant
0 Likes
874
  l_col_pos = 1.
  gt_fieldcat-fieldname = 'CHECKBOX'.
*  declaring field as checkbox and
*  mark it as editable field:
  gt_fieldcat-checkbox = 'X'.
  gt_fieldcat-edit = 'X'.
  gt_fieldcat-tabname = 'GT_ESH'.
  gt_fieldcat-outputlen = 10.
  gt_fieldcat-coltext = text-f01.
  gt_fieldcat-tooltip = text-f01.
  gt_fieldcat-seltext = text-f02.
  gt_fieldcat-col_pos = l_col_pos.
  append gt_fieldcat.
  clear  gt_fieldcat.

* Work Area Description.
  l_col_pos = l_col_pos + 1.
  gt_fieldcat-fieldname  = 'WANAM'.
  gt_fieldcat-key = 'X'.
  gt_fieldcat-tabname   = 'GT_ESH'.
  gt_fieldcat-outputlen = '60'.
  gt_fieldcat-emphasize = 'X'.
  gt_fieldcat-tooltip    = text-f02.
  gt_fieldcat-coltext    = text-f02.
  gt_fieldcat-seltext    = text-f02.
  gt_fieldcat-col_pos    = l_col_pos.
  append gt_fieldcat.
  clear  gt_fieldcat.

  l_col_pos = l_col_pos + 1.
  gt_fieldcat-fieldname  = 'WAPLANT'.
  gt_fieldcat-key = 'X'.
  gt_fieldcat-tabname   = 'GT_ESH'.
  gt_fieldcat-outputlen = '8'.
  gt_fieldcat-emphasize = 'X'.
  gt_fieldcat-tooltip    = text-f02.
  gt_fieldcat-coltext    = text-f02.
  gt_fieldcat-seltext    = text-f02.
  gt_fieldcat-col_pos    = l_col_pos.
  append gt_fieldcat.
  clear  gt_fieldcat.

This is the field catalog code i developed.however in the display checkbox is appearing as the last column.

i want it to be in first column.how to fix this...

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
711

Not sure, but try adding:

  gt_fieldcat-key = 'X'.

To the checkbox.

Rob

  l_col_pos = 1.
  gt_fieldcat-fieldname = 'CHECKBOX'.
*  declaring field as checkbox and
*  mark it as editable field:
  gt_fieldcat-checkbox = 'X'.
  gt_fieldcat-edit = 'X'.
  gt_fieldcat-tabname = 'GT_ESH'.
  gt_fieldcat-outputlen = 10.
  gt_fieldcat-coltext = text-f01.
  gt_fieldcat-tooltip = text-f01.
  gt_fieldcat-seltext = text-f02.
  gt_fieldcat-col_pos = l_col_pos.
  append gt_fieldcat.
  clear  gt_fieldcat.

* Work Area Description.
  l_col_pos = l_col_pos + 1.
  gt_fieldcat-fieldname  = 'WANAM'.
  gt_fieldcat-key = 'X'.
  gt_fieldcat-tabname   = 'GT_ESH'.
  gt_fieldcat-outputlen = '60'.
  gt_fieldcat-emphasize = 'X'.
  gt_fieldcat-tooltip    = text-f02.
  gt_fieldcat-coltext    = text-f02.
  gt_fieldcat-seltext    = text-f02.
  gt_fieldcat-col_pos    = l_col_pos.
  append gt_fieldcat.
  clear  gt_fieldcat.

  l_col_pos = l_col_pos + 1.
  gt_fieldcat-fieldname  = 'WAPLANT'.
  gt_fieldcat-key = 'X'.
  gt_fieldcat-tabname   = 'GT_ESH'.
  gt_fieldcat-outputlen = '8'.
  gt_fieldcat-emphasize = 'X'.
  gt_fieldcat-tooltip    = text-f02.
  gt_fieldcat-coltext    = text-f02.
  gt_fieldcat-seltext    = text-f02.
  gt_fieldcat-col_pos    = l_col_pos.
  append gt_fieldcat.
  clear  gt_fieldcat.

This is the field catalog code i developed.however in the display checkbox is appearing as the last column.

i want it to be in first column.how to fix this...

4 REPLIES 4
Read only

Former Member
0 Likes
712

Not sure, but try adding:

  gt_fieldcat-key = 'X'.

To the checkbox.

Rob

Read only

SG141
Active Participant
0 Likes
711

Yup!!! it works

Read only

0 Likes
711

Nice -:) Could you please assign points and close the thread...

Greetings,

Blag.

Read only

Former Member
0 Likes
711

Rob is right...You should add


gt_fieldcat-key = 'X'.

To your checkbox...Why? Because KEY fields always starts first...If the checkbox is not a KEY, then it should appear after the KEY fields -;)

Greetings,

Blag.