Page 1 of 1

how to input parameter value into script?

Posted: Wed Aug 27, 2008 10:37 pm
by kkktank

Code: Select all

TYPES: BEGIN OF HEADER,
        VBELN LIKE VBAK-VBELN,
  END OF HEADER.
DATA HEADER TYPE HEADER.
HEADER-VBELN = '12345'.
In window 'header'
/E FIRST_LINE
T1 SO No.:,, &HEADER-VBELN&,,

Code: Select all

  CALL FUNCTION 'WRITE_FORM'
   EXPORTING
     ELEMENT                        = 'FIRST_LINE'
     WINDOW                         = 'HEADER'
            .
Why no VBELN output ?
When I debug into the script, I found the &HEADER-VBELN& has no value.

In smartforms, the field symbol must be add by the 'add field' button but I found no differnce in Script.

Re: how to input parameter value into script?

Posted: Thu Aug 28, 2008 3:02 am
by abap_doctor
Have you taken a look at FM: TEXT_SYMBOL_SETVALUE? 8)

But I seem to remember this wasn't required, and your method was sufficient... :?

Re: how to input parameter value into script?

Posted: Tue Sep 02, 2008 3:51 pm
by wilhitern1
I don't remember when non-main windows occur. Perhaps at open. All non-main windows print on their own at a specific time. Only main needs to be called as I remember.

Re: how to input parameter value into script?

Posted: Tue Sep 02, 2008 9:35 pm
by kkktank
wilhitern1 wrote:I don't remember when non-main windows occur. Perhaps at open. All non-main windows print on their own at a specific time. Only main needs to be called as I remember.
The fields did have value before openning the form. And I think the non-main windows will be printed by the commands of program.
I think this is only a little tiny problem, but rather annoying me. :twisted:

Re: how to input parameter value into script?

Posted: Wed Sep 03, 2008 7:53 am
by wilhitern1
What version are you on?

Is the print program too big to post?

When it runs, do you see "T1 SO No.:" with no number or do neither print?