on 12-12-2006 10:56 PM
Hi friends ,
I am getting the following program in the form .
&t_work-desc&,,&t_work-desc1&,,&t_work-seconds&,,&w_amount&
Unknown symbol w_amount
,,&w_amount1&
Unknown symbol w_amount1.
In the print program i have defined it as follows .
DATA : w_amount(15) TYPE c ,
w_amount1(15) TYPE c.
Loop at t_work.
MOVE t_work-amount TO w_amount.
MOVE t_work-amount1 TO w_amount1.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
element = 'savings'
window = 'MAIN'
EXCEPTIONS
window = 1
element = 2.
endloop.
Please tell me why it is not recognising the 2 other w_amount and w_amount1 elements .
Thanks ,
HARI
Message was edited by:
Hari G Krishna
I don't think this will solve the problem, but I really don't know what the problem is, so here is a guess. Try to capitalize the element in the function call.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
element = 'SAVINGS' "<- Right here
window = 'MAIN'
EXCEPTIONS
window = 1
element = 2.
Regards,
RIch Heilman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Paragraph format D1 : FONT 8.0
Actual code in the main window .
/ E SAVINGS
D1 &t_work-desc&,,&t_work-seconds&,,&t_work-rate&,,
= &w_amount&,,&w_amount1&
Error when checked for text
= &w_amount&,,&w_amount1&
Unknown symbol W-EARN_AMT
Unknown symbol W-EARN_YTD
In the print program .
Defn in the Main Program .
Data: w_amount(15) TYPE c,
w_amount1(15) TYPE c.
in the include program .
Loop at t_work.
w_amount = t_work-amt .
w_amount1 = t_work-ytd .
CALL FUNCTION 'WRITE_FORM'
EXPORTING
element = 'SAVINGS'
window = 'MAIN'
EXCEPTIONS
window = 1
element = 2.
endloop.
Hi Friends ,
Finally it worked . There was no problem when I tested the form in the testing client . I think I should not be worried when I get error while doing TEXT check . Though it said undefined symbol still i got the value on the form . I would like to thank Rich and other friends to have guided me thru this issue . I think I am leaning the hard way
Regards,
Hari
Hi,
All the variables used in SAPSCRIPT should be declared globally in the print program and not inside a subroutine..
Thanks,
Naren
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
When are you getting this error? Are the W_AMOUNT and W_AMOUNT1 defined in the top of the program(and not inside a FORM subroutine)?
Regards,
Rich Heilman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.