2013 Aug 22 8:20 AM
Hello All,
I have a view cluster and two view cluster variant. In the screen I have a table with few columns. For one of the view cluster variants, I want to hide one of the columns of the table. Since both the view cluster variant is linked to the same view cluster that is to the same screen, I am dynamically suppressing the column w.r.t the view cluster variant.
This is the piece of code I have written:
loop at screen.
if screen-name = 'FSH_SOFN_V-DOCTYPE' and fsh_sofn_v-soobj = 'ST'.
screen-input = '0'.
screen-output = '0'.
screen-invisible = '1'.
screen-active ='0'.
modify screen.
endif.
ENDLOOP.
This piece of code hides the values of this particular screen field, but it is still shown in the UI. I want to completely remove it from the UI whenever I execute the view variant.
I feel Since I have not written any code to remove it from the table control of the screen , it is still shown in the Table at UI.
The screens developed here are done from table maintenace generator , so it's all automated. Not getting how to change the table control values.
Could you please provide your inputs.??
I have attached a screenshot where I have highlighted the column to be removed.
2013 Aug 22 8:39 AM
Hello All,
I have a view cluster and two view cluster variant. In the screen I have a table with few columns. For one of the view cluster variants, I want to hide one of the columns of the table. Since both the view cluster variant is linked to the same view cluster that is to the same screen, I am dynamically suppressing the column w.r.t the view cluster variant.
This is the piece of code I have written:
loop at screen.
if screen-name = 'FSH_SOFN_V-DOCTYPE' and fsh_sofn_v-soobj = 'ST'.
screen-input = '0'.
screen-output = '0'.
screen-invisible = '1'.
screen-active ='0'.
modify screen.
endif.
ENDLOOP.
This piece of code hides the values of this particular screen field, but it is still shown in the UI. I want to completely remove it from the UI whenever I execute the view variant.
I feel Since I have not written any code to remove it from the table control of the screen , it is still shown in the Table at UI.
The screens developed here are done from table maintenace generator , so it's all automated. Not getting how to change the table control values.
Could you please provide your inputs.??
I have attached a screenshot where I have highlighted the column to be removed.
2013 Aug 22 8:39 AM
2013 Aug 22 9:31 AM
Hi Arun,
I am trying to implement the above solution. I am facing some issues.
I have used a table maintenance generator. So Depending on the Fields I have choosed, screen is automatically generated with table control : TCTRL_FSH_SOFN_V.
Now, I have to declare a work area to store the values of the above type.
How do i do it??
The highlighted portion gives an syntax error as the table control is not defined.
data: wa_FSH_SOFN_V_cols type LINE OF TCTRL_FSH_SOFN_V-COLS.
loop at TCTRL_FSH_SOFN_V-COLS to wa_FSH_SOFN_V_cols."into .
if sytabix = 4.
wa_FSH_SOFN_V_cols-INVISIBLE = 1.
MODify TCTRL_FSH_SOFN_V-COLS from wa_FSH_SOFN_V_cols.
endif.
endloop.
2013 Aug 22 12:09 PM
Rohit,
Declare using like instead of type.
data: wa_FSH_SOFN_V_cols LIKE LINE OF TCTRL_FSH_SOFN_V-COLS.
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |