‎2007 Nov 23 7:21 AM
Hi All,
Thanx in advance n will award points for the usefull answers
Please help me out from the following situation
I have a table control. i have 3 buttons on it. INSERT, DELETE and SAVE.
When ever i SAVE the data in the table control saves into table ZVTW.
so my point is right now iam having 2 records in the table control from the table ZVTW. now am clicking on the insert button so that it enables one record to enter the data into it. 4 fields are mandatory. without entering any data iam trying to save. iam showing one error message 'PLEASE ENTER MANDATORY FIELDS'.
fileds are getting disabled.
Now i need to enable the fields again to enter the data.
Please help me out.
‎2007 Nov 23 7:25 AM
Hi ,
Use AT SELECTION-SCREEN ON <Fieldname > FOR <Fieldname >
Thanks,
Poonam
‎2007 Nov 23 7:27 AM
Use AT SELECTION-SCREEN ON <Fieldname > -
for Parameter
or AT SELECTION-SCREEN ON <Fieldname > FOR <Fieldname >-low
---For select options.
‎2007 Nov 23 7:33 AM
Hi Poonam,
those fields are either parameters or selectoptions. those are from a tablecontrol.
Please let me know how to use that type of condition for tablecontrol.
Thanx in advance.
‎2007 Nov 23 7:26 AM
well in this case dont put a error message .. try putting in a warning message so that the fields will remain input enabled ...
‎2007 Nov 23 7:31 AM
Hi Rohit i tried with warning message. however the fields are still disabled
‎2007 Nov 23 7:34 AM
ya eric is quiet write .. u have to validate the fields using chain endchain statement .. for more details in this press f1 on chain to see detials .
‎2007 Nov 23 7:31 AM
hi,
in table control loop you have to place CHAIN...ENDCHAIN
CHAIN.
FIELD ...
do the chck, issue error message and all the fields, which are listed here (with FIELDS statement) will be open
ENDCHAIN
hope this helps
ec
‎2007 Nov 23 7:37 AM
Hi Eric,
I already used the CHAIN and ENDCHAIN on the fields. But still it is disabled.
‎2007 Nov 23 7:38 AM
‎2007 Nov 23 7:43 AM
process before output.
PBO FLOW LOGIC FOR TABLECONTROL 'TCTRL_CYL_RECOV'
module tctrl_cyl_recov_init.
MODULE TCTRL_CYL_RECOV_CHANGE_TC_ATTR.
MODULE TCTRL_CYL_RECOV_CHANGE_COL_ATTR.
loop at g_tctrl_cyl_recov_itab
into g_tctrl_cyl_recov_wa
with control tctrl_cyl_recov
cursor tctrl_cyl_recov-current_line.
MODULE TCTRL_CYL_RECOV_CHANGE_FIELD_ATTR
module tctrl_cyl_recov_move.
module tctrl_cyl_recov_get_lines.
endloop.
module status_2030.
*
process after input.
PAI FLOW LOGIC FOR TABLECONTROL 'TCTRL_CYL_RECOV'
loop at g_tctrl_cyl_recov_itab.
chain.
field zvtw-matnr.
field zvtw-zserialid.
field zvtw-zccylcd.
field zvtw-zprotx.
field zvtw-zcweiqy.
field zvtw-zowfl.
field zvtw-zrweiqy.
field zvtw-zrecd.
field zvtw-zoucd.
field zvtw-zpweiqy.
field zvtw-zrstatuscd. "mod010
field zvtw-zdserialno. "mod010
*{ INSERT DGEK970544 1
field zvtw-zdispcd. "mod013
field zvtw-zconsno. "mod013
field zvtw-zconsdt. "mod013
field zvtw-zcustrepdt. "mod013
field zvtw-zearepdt. "mod013
*} INSERT
field zvtw-zdprocdt. "mod010
module tctrl_cyl_recov_modify on chain-request.
endchain.
field g_tctrl_cyl_recov_wa-flag
module tctrl_cyl_recov_mark on request.
chain. "mod010
field zvtw-zdserialno. "mod010
field zvtw-zdprocdt. "mod010
module tctrl_cyl_recov_check on chain-request. "mod010
endchain. "mod010
endloop.
field ztq_flds-zzhazdcd "Mod016
module m2030_validate_hazcd on request. "Mod016
module tctrl_cyl_recov_user_command.
MODULE TCTRL_CYL_RECOV_CHANGE_TC_ATTR.
MODULE TCTRL_CYL_RECOV_CHANGE_COL_ATTR.
<u><i><b> module user_command_2030. </b></i></u>
process on value-request. "mod010
field zvtw-zserialid module zserialid_f4_v1. "mod010
‎2007 Nov 23 7:44 AM
‎2007 Nov 23 7:46 AM
which fields have he problem?
in which module do you issue the error message?
‎2007 Nov 23 7:47 AM
do you mean in module user_command_2030? That is not good, it has to be between CHAIN and ENDCHAIN.
‎2007 Nov 23 8:07 AM
dont write it in ur user command module .. write it in a module inide ur chain endchain statemnt .
‎2007 Nov 23 8:14 AM
yes but that module will be in loop and will it give any problem in the functionality
‎2007 Nov 23 8:16 AM
no not at all .. infact it should be in loop so that ur each data of ur table control is properly validated .
‎2007 Nov 23 8:30 AM
hi rohit,
i tried this and iam facing strange problem. though i have a record in the first line it is giving a warning to enter record.
‎2007 Dec 18 7:20 AM
‎2008 Feb 04 2:22 PM
hi
i read yr post. I gt similar problem in my table control. My field is disable after a message class. How u resolve the problem which u the field can be enable. Thank urgent.