Skip to Content
avatar image
Former Member

can call to 'WRITE_FORM' three times

Hi abappers. happy year

Why i can call to 'WRITE_FORM' two times, but i can´t call to 'WRITE_FORM' other times.

it leaves the next error:

"WRITE_FORM não é permitido, porque falta

START_FORM"

-

-


CALL FUNCTION 'OPEN_FORM'

EXPORTING

form = 'ZNOVALE_OST_PRU1'

device = 'PRINTER'

dialog = 'X'

language = SY-LANGU

EXCEPTIONS

canceled = 1

device = 2

form = 3

options = 4

unclosed = 5.

IF SY-SUBRC NE 0.

WRITE /'error al abrir formulario'.

STOP.

ENDIF.

loop at T_DATA1.

CALL FUNCTION 'START_FORM'

EXPORTING

startpage = 'FIRST'.

CALL FUNCTION 'WRITE_FORM'

EXPORTING

window = 'CABECERA'.

CALL FUNCTION 'WRITE_FORM'

EXPORTING

window = 'MAIN'.

continue

-

-


I want put the next code:

CALL FUNCTION 'WRITE_FORM'

EXPORTING

window = 'FIRMA'.

-

-


continue

CALL FUNCTION 'END_FORM'.

endloop.

CALL FUNCTION 'CLOSE_FORM'.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Dec 31, 2007 at 11:39 AM

    Hi Lopez,

    Write the Code Like this...

    Write WRITE_FORM in Between START_FORM and END_FORM.

    Another WRITE_FORM in Between START_FORM and END_FORM.

    Another WRITE_FORM in Between START_FORM and END_FORM.

    CALL FUNCTION 'OPEN_FORM'

    CALL FUNCTION 'START_FORM'

    CALL FUNCTION 'WRITE_FORM'

    CALL FUNCTION 'END_FORM'

    CALL FUNCTION 'START_FORM'

    CALL FUNCTION 'WRITE_FORM'

    CALL FUNCTION 'END_FORM'

    CALL FUNCTION 'START_FORM'

    CALL FUNCTION 'WRITE_FORM'

    CALL FUNCTION 'END_FORM'

    CALL FUNCTION 'CLOSE_FORM'.

    Edited by: Vishnu Reddy on Dec 31, 2007 5:34 PM

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Dec 31, 2007 at 12:20 PM

    Hi Lopez,

    The layout set can be changed in the current print procedure with START_FORM. It is therefore possible to combine several different layout sets in one printer output. Before a new layout set is opened with START_FORM, an open layout set must be closed with END_FORM.

    Hence call your write_form in between the start_form and end_form. You may come out of the issue.

    Thanks,

    Ananth

    Add comment
    10|10000 characters needed characters exceeded