on 08-04-2008 11:31 AM
Hi,
I have given some code like this in the form
LOOP AT ITEMKOND ASSIGNING <ITEMKOND>.
TAMOUNT = TAMOUNT + <ITEMKOND>-AMOUNT.
ENDLOOP.
When I try to activate the program,it is giving error as 'ITEMKOND is a table without a header line.Hence no component called AMOUNT.
When do we get this error?
hi,
Follow like this,
Create a workarea WA_KOND for ITEMKOND IN GLOBAL DECLARATION.
And write the code as
LOOP AT ITEMKOND INTO WA_KOND.
AMOUNT = TAMOUNT + WA_KOND-AMOUNT.
ENDLOOP.
Reward if it is usefull,
Regards,
KP
Edited by: krishna prasad on Aug 4, 2008 12:48 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
In global definitions I have declared the internal table and workarea like this.
ITEMKOND TYPE TABLE OF ZGTI2C_PRICE_ITEMKOND.
ITEMKOND_WA LIKE ZGTI2C_PRICE_ITEMKOND.
I have used them in the following code.
LOOP AT ITEMKOND INTO ITEMKOND_WA.
TAMOUNT = TAMOUNT + ITEMKOND_WA-AMOUNT.
ENDLOOP.
But still it is giving the same error as 'ITEMKOND is a table without a header line.Hence no component called AMOUNT'.
Can anyone tell me some solution for this.
Try this...
ITEMKOND TYPE STANDARD TABLE OF ZGTI2C_PRICE_ITEMKOND.
ITEMKOND_WA LIKE ZGTI2C_PRICE_ITEMKOND.
since it is a amount field u have to declare(ALL of them) them in the currency/quantity tab of the global definition..
ITEMKOND_WA-AMOUNT like ITEMKOND_WA-AMOUNT
Edited by: Pratik Mallick on Aug 4, 2008 4:47 PM
Hi Pratik,
Already there is a loop node in the form.In that they have declared like this.
LOOP AT ITEMKOND ASSIGNING <ITEMKOND>.
Under this loop node I have declared one program lines node and gave the following code.
TAMOUNT = TAMOUNT + <ITEMKOND>-AMOUNT.
But it is giving error as '<ITEMKOND>-AMOUNT is unknown'
Could you please tell me how to resolve this.
define amount parameter in global definitions
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Create a workarea for ITEMKOND and then
Loop at ITEMKOND into workarea and then do the validation as per requirements.
Regards..
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 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.