06-27-2007 1:34 PM
Hi,
I have developed two screens .
in the first screen the user enters the data and press the Next Push button then
in the second screen it should display data in the table control.
For that purpose I have written code.
when the user press Next Button then I wrote like this.
case ok_code.
when 'NEXT'.
CALL SCREEN '9001'.
ENDCASE.
AND In the PBO Event of the Screen 9001 I have written a Function Module to Popup the data
in the table control.
But the problem is when the user press the Next Button it is displaying table control without
data. But when the press the Back button and again he press the Next Button then it is displaying.
So, Where is the Problem ?
How can I correct it ?
Bye,
Satya.
06-27-2007 1:39 PM
Hi,
I think you are fetching the data into the internal table after the loop pass for the table control in PBO event.Make the data fetching before the loop pass in table control.
Process Before Output.
Module fetch_data.
Loop at itab with control tc cursor tc-current_line.
Endloop.
06-27-2007 1:39 PM
Hi,
I think you are fetching the data into the internal table after the loop pass for the table control in PBO event.Make the data fetching before the loop pass in table control.
Process Before Output.
Module fetch_data.
Loop at itab with control tc cursor tc-current_line.
Endloop.
06-27-2007 1:42 PM
06-27-2007 1:40 PM
u should display the data when the user presses the NEXT button. so, write code to select data in PBO and display the data when user presses NEXT button...
06-27-2007 1:42 PM
Hi
IN PAI
case ok_code.
when 'NEXT'.
select the data into an internal table using the entered fields in the first screen.
so data is there in ITAB.
CALL SCREEN '9001'.
ENDCASE.
in PBO.
between loop..
MOVE the internal table data to the table control fields
endloop.
see the help for TC
syntax:
CONTROLS .
if you only want to determine the row of the table control. SY´-SUBRC allows you to check if the cursor is placed in a row of a table control.
u need to comment the performs of table control fields and write ur own perform statements. And u have to declare the table control fields as separate internal tables.
Go through this urls.
Check the below links.
http://www.planetsap.com/howdo_a.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/9f/dbac5135c111d1829f0000e829fbfe/content.htm
http://sap.niraj.tripod.com/id25.html
Reward points for useful Answers
Regards
Anji