2014 Nov 26 10:18 AM
Hi Experts,
I have a tabstrip with two tabs.
Each tab has one tablecontrol.
At the bottom of table control i have given insert button.
When i enter data in first tab and switch to another tab and enter data and come back to first tab and again go back to second tab, data is lost in second tab.
I have attached the screenshot.
Any inputs will be greatly appreciated.
2014 Nov 26 1:59 PM
Insure in the PAI of both subscreen that you saved changed data into program internal tables :
subscreen PAI logic
PROCESS AFTER INPUT.
LOOP AT itab.
MODULE tabctrl_old. " Read program itab
CHAIN.
FIELD itab-field1. " Now read new values from screen
FIELD itab-field2.
MODULE tabctrl_upd ON CHAIN-REQUEST. " If data changed, update itab
ENDCHAIN.
ENDLOOP.
Also in main screen logic PAI only execute user_command (exception : exit command) after subscreen logic
PROCESS AFTER INPUT.
MODULE user_command AT EXIT-COMMAND.
CALL subscreen subscreenarea.
MODULE user_command.
Regards,
Raymond
Hi Experts,
I have a tabstrip with two tabs.
Each tab has one tablecontrol.
At the bottom of table control i have given insert button.
When i enter data in first tab and switch to another tab and enter data and come back to first tab and again go back to second tab, data is lost in second tab.
I have attached the screenshot.
Any inputs will be greatly appreciated.
2014 Nov 26 10:34 AM
Hi Kulprakash,
Please make sure that you don't refresh the internal table in which you are fetching data and displaying in tabstrip tab2.
Please refresh it on save event or any necessary event only.
Regards,
Sagar
2014 Nov 26 1:59 PM
Insure in the PAI of both subscreen that you saved changed data into program internal tables :
subscreen PAI logic
PROCESS AFTER INPUT.
LOOP AT itab.
MODULE tabctrl_old. " Read program itab
CHAIN.
FIELD itab-field1. " Now read new values from screen
FIELD itab-field2.
MODULE tabctrl_upd ON CHAIN-REQUEST. " If data changed, update itab
ENDCHAIN.
ENDLOOP.
Also in main screen logic PAI only execute user_command (exception : exit command) after subscreen logic
PROCESS AFTER INPUT.
MODULE user_command AT EXIT-COMMAND.
CALL subscreen subscreenarea.
MODULE user_command.
Regards,
Raymond
2014 Dec 08 1:00 PM
I got my problem solved.
I kept one flag to prevent overwriting of new value by old value.