on 2005 Dec 02 4:56 PM
Hi, how can i set some fields to edit in my alv, using 'REUSE_ALV_GRID_DISPLAY'??
the structure slis_specialcol_alv is only for set the collor??
thanks
Alexandre Nogueira .
Do you mean to say,edit few cells in one column??
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Alex
I have solution for you...
You need to Do few Steps...
1. Create An additional field in your final Internal Table.
<b>HANDLE_STYLE TYPE LVC_T_STYL.</b>
2. In layout
<b> GS_LAYOUT-STYLEFNAME = 'HANDLE_STYLE'.</b>
<b>3.populate field catalog</b>
4.Before Calling Method do this
i will give you some explanation
here i am setting a flag based on some data, for that data i am making the cells disable to edit.
DATA: LS_EDIT TYPE LVC_S_STYL,
LT_EDIT TYPE LVC_T_STYL.
LOOP AT IT_FINAL INTO LS_OUTTAB WHERE FLAG = 'X'.
V_INDEX = SY-TABIX.
LS_EDIT-FIELDNAME = 'MATNR'.
LS_EDIT-STYLE = CL_GUI_ALV_GRID=>MC_STYLE_DISABLED.
LS_EDIT-STYLE2 = SPACE.
LS_EDIT-STYLE3 = SPACE.
LS_EDIT-STYLE4 = SPACE.
LS_EDIT-MAXLEN = 8.
INSERT LS_EDIT INTO TABLE LT_EDIT.
LS_EDIT-FIELDNAME = 'POSNR'.
LS_EDIT-STYLE = CL_GUI_ALV_GRID=>MC_STYLE_DISABLED.
LS_EDIT-STYLE2 = SPACE.
LS_EDIT-STYLE3 = SPACE.
LS_EDIT-STYLE4 = SPACE.
LS_EDIT-MAXLEN = 8.
INSERT LS_EDIT INTO TABLE LT_EDIT.
INSERT LINES OF LT_EDIT INTO TABLE LS_OUTTAB-HANDLE_STYLE.
MODIFY IT_FINAL INDEX V_INDEX FROM LS_OUTTAB TRANSPORTING
HANDLE_STYLE DROP_DOWN_HANDLE.
MODIFY IT_FINAL_TMP INDEX V_INDEX FROM LS_OUTTAB TRANSPORTING
HANDLE_STYLE DROP_DOWN_HANDLE.
ENDLOOP
.
then call the method set table for first display...
Yes...Just pass this parameter for the colume you want to edit.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
In the field catalog set attribute EDIT = 'X'.
for e.g.
LOOP AT it_fieldcat_src INTO wa_fieldcat.
CASE wa_fieldcat-fieldname.
WHEN 'XXXXXX'.
wa_fieldcat-col_pos = '1'.
wa_fieldcat-outputlen = '11'.
wa_fieldcat-seltext_l = text-009.
wa_fieldcat-edit = 'X'.
ENDCASE.
MODIFY it_fieldcat_src FROM wa_fieldcat INDEX sy-tabix.
ENDLOOP.
Regards
Kalpana
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Use the structure SLIS_LAYOUT_ALV & the fiedl name is EDIT.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ALex
do it in fieldcat.....
X_FIELDCAT-SCRTEXT_M = 'MATNR'(023).
X_FIELDCAT-FIELDNAME = 'MATNR'.
X_FIELDCAT-TABNAME = 'IT_FINAL'.
X_FIELDCAT-COL_POS = L_POS.
X_FIELDCAT-OUTPUTLEN = '10'.
X_FIELDCAT-EDIT = 'X'.
<b> CALL METHOD G_GRID1->SET_TABLE_FOR_FIRST_DISPLAY
EXPORTING
IT_TOOLBAR_EXCLUDING = LT_EXCLUDE
IS_VARIANT = LS_VARI
I_SAVE = 'A'
IS_LAYOUT = GS_LAYOUT1
CHANGING
IT_FIELDCATALOG = IT_FIELDCAT1
IT_OUTTAB = IT_VEKP1[].
after call method you need to call this method..
** Set editable cells to ready for input initially
CALL METHOD G_GRID1->SET_READY_FOR_INPUT
EXPORTING
I_READY_FOR_INPUT = 1.</b>
User | Count |
---|---|
70 | |
10 | |
10 | |
7 | |
6 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.