cancel
Showing results for 
Search instead for 
Did you mean: 

Scripts

Former Member
0 Kudos

Hi folks,

What is the use of start_form?

To open a form in script open_form FM is used. We can done this by using start_form without using the open_form?

Thanks in advance

Ravi

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi,

start_form is to be used when you have more than one form..and each form is opened using open_form.

start_form encloses many open_forms.

regards,

pankaj singh

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi Ravi,

Let me share some ideas with u.

suppose u r developing a single script, then call opn form in u r program for open the script form and start form in u r program for initialte the layout set. you can mention your scrit name in any of these function modules.

Suppose u developed 2 layout sets like one is potrait and land scape. Then in taht scenario in u r program write one open form and write 2 start forms. One is for potrait and another is for land scape. Then at a time 2 layout sets can be passed to output instead of different,

Hope this helps you. Already i got some idea due to this u will get some clarity....

Reply for quereis.

Regards,

Kumar.

Former Member
0 Kudos

hi,

open_form is used to open form it is a mandatery to open a form.

we are not able to open a form through start_form

i will explain this to u

one open,close form we can create one spool requiste.

wnder that one spool requiste u have utilised more than one form then the real neeed of start_form,end_form is required.

if u have further query ask me this is help full to u , i feel

Former Member
0 Kudos

Hi Sunil,

Thanks for your quick response. To be frank until now I dont have clarity on these. Am thinking that open_form is used to open the form by giving the form name and device. Start_form is used when we have 2 (assume) layouts of different layout settings and we want to get the print of that 2 different layouts one by one then we have to open the start_form for first form and end it by using end_form. After that once again we have to open start_form for second form and end it by using end_form. And these start_forms is put in a loop.

am thinking this is the way we have to use the start_form. Please confirm me it is correct or wrong?

Sorry for my english

Thanks

Ravi

Former Member
0 Kudos

U are exactly corerect ...if u want to use more that one form in a driver program. u have to call tru Start_form...

-Anil

former_member673464
Active Contributor
0 Kudos

HI,

To initialize the printing use function modules (OPEN_FORM und CLOSE_FORM) .

With OPEN_FORM, you can change the option for the current printout.

If you do not specify a form with OPEN_FORM, you must at a later time call START_FORM. In this case, the form specified with START_FORM determines where to print. If you use 'X' or 'Space' with START_FORM, you can change the value set with the form, as described for OPEN_FORM. As with SAPscript form printing, you must always call the function module END_FORM after using START_FORM.

OPEN_FORM :

The function module OPEN_FORM opens form printing. You must call this function module before you can use any other form function (WRITE_FORM, START_FORM, CONTROL_FORM...).

You need not specify a form name. If you omit the name, you must use the function module START_FORM to open a form before starting the output.

You must end form printing by using the function module CLOSE_FORM. Otherwise, the system does not print or display anything.

Within a program, you can use several OPEN_FORM.. CLOSE_FORM pairs. This allows you to write output to several different spool requests from within one program.

START_FORM:

In-between the function modules OPEN_FORM and CLOSE_FORM, you can use different forms. This allows you to combine several different forms into one print output. However, you can combine only those forms that have the same page format.

To switch forms, use the function module START_FORM. If another form is still open, you must close it first using END_FORM.

If you specify no form name when calling START_FORM, the system restarts the last open form. If after OPEN_FORM no form was activated yet, the system leaves the function module with the exception UNUSED.

REGARDS,

VEERESH

amit_khare
Active Contributor
0 Kudos

Open_form => It assign the form and printer, It should be first.

Start_form => It start Writing mode. You can use write_form in loop to write more than one lines befor End_form.

End_form => It end writing mode of current page and will require to start again through Start_form.

Close_form=> it end the Form. After this you can not start again for created file.

Regards,

Amit

Former Member
0 Kudos

Hi,

START_FORM

In-between the function modules OPEN_FORM and CLOSE_FORM, you can use different forms. This allows you to combine several different forms into one print output. However, you can combine only those forms that have the same page format.

To switch forms, use the function module START_FORM. If another form is still open, you must close it first using END_FORM.

If you specify no form name when calling START_FORM, the system restarts the last open form. If after OPEN_FORM no form was activated yet, the system leaves the function module with the exception UNUSED.

Function call:

CALL FUNCTION 'START_FORM'

EXPORTING FORM = SPACE

LANGUAGE = SPACE

STARTPAGE = SPACE

PROGRAM = SPACE

ARCHIVE_INDEX = SPACE

IMPORTING LANGUAGE =

EXCEPTIONS FORM =

FORMAT =

UNENDED =

UNOPENED =

UNUSED =

http://help.sap.com/saphelp_47x200/helpdata/en/d6/0dba34494511d182b70000e829fbfe/content.htm

CLOSE_FORM

The function module closes the form opened using OPEN_FORM. The system executes any terminating processing steps for the last opened form.

You must use this function module to close form printing. Otherwise, no output appears on printer or screen.

Function call:

CALL FUNCTION 'CLOSE_FORM'

IMPORTING RESULT =

TABLES OTFDATA = ?...

EXCEPTIONS UNOPENED =

http://help.sap.com/saphelp_47x200/helpdata/en/d6/0dba27494511d182b70000e829fbfe/content.htm.

The above function modules are used between OPEN_FORM and CLOSE_FORM.

If you want to call a different form or the same form with different print parameters ...in such scenarios the above function modules can be used.

Kishi.