‎2007 Mar 25 7:52 AM
IF I'm reading data from tables spfil and sflight do it use FM ( open / wite and close ) twice
‎2007 Mar 25 11:32 AM
Not necessary. If u r reading these 2 tables and u r having the data in an internal table, then just open the form once and the main window. Then follow the logic as below.
perform begin_form.
Perform OPEN_FORM using formaname windowname etcc..
Loop at itab into wa.
perform write_form using textelementname
endloop.
perform close_form.
perform end_form.
after this make sure u put the wa fields in the form's main window correctly.
&wa_flightname&,,&wa-flightno& etc...
Award points if useful....
Cheers,
Sam
‎2007 Mar 25 11:32 AM
Not necessary. If u r reading these 2 tables and u r having the data in an internal table, then just open the form once and the main window. Then follow the logic as below.
perform begin_form.
Perform OPEN_FORM using formaname windowname etcc..
Loop at itab into wa.
perform write_form using textelementname
endloop.
perform close_form.
perform end_form.
after this make sure u put the wa fields in the form's main window correctly.
&wa_flightname&,,&wa-flightno& etc...
Award points if useful....
Cheers,
Sam
‎2007 Mar 26 7:04 AM
Hi Shaheen,
Yes, as per sahmuel solution we can do it.
Hope this helps you, reply for queries, Shall post you the updates.
Regards.
Kumar.
‎2007 Mar 26 7:13 AM
Hi,
First you need to create an Internal table to hold the data from the 2 tables (Sflight and Spfli), and after having the final data in the Internal table, then start the Function modulus.
after that you need call the Transaction and pass al the screens ok codes with the internal table data to the BDCDATA structure
CALL the OPEN_FORM function module to open the Session, then call the WRITE form to pass the BDCDATA structure and then call the CLOSE_FORM function module to close the session.
Regards
Sudheer