on 06-14-2007 5:36 AM
Hi,
Iam generating a smart form and am extracting the data from the database table to display in the smart form. When i give currency field to the amount field it is givin an error as<b> " Reference field W_ZMAINDOC1-DOC_AMOUNT unknown in form.
"</b> ......... Could anybody help me out ASAP..
Thanks
Shiva shekar k
hi shiva,
at the smartforms u should define like this for cureency/quntity fields,
go to global definations,
select currency/quntity fields tab,
there define as follows.
Field Name Reference Field Data Type
L_WA_ITAB-NETWR WAERK CURR
then save and activate to work.
reward points if helpful.
regards,
seshu.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
use type P instead of currency..
Regards,
Sairam
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Create a character variable..And then assign the amount to the character variable..
Then print the character variable..
Thanks,
Naren
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi check this...
In the ABAP Dictionary, you can assign a currency or quantity field to a table field if the table field contains a currency or quantity value. When printing these fields, SAP Smart Forms can take into account the assigned currency or unit:
If the value field is in the same table as the assigned currency or quantity field, SAP Smart Forms automatically recognizes this and, during output, formats the value field according to the currency or unit in the assigned field.
If the value field and the assigned currency or quantity field are stored in different tables, SAP Smart Forms cannot automatically recognize the relationship.
In the second case, you must inform SAP Smart Forms about the relationship.
Procedure
As mentioned above, you only have to perform the following steps if a value field that is to be displayed in a table (for example, VALTAB) has a relationship to a currency or quantity field in another table (for example, CURTAB). In this case, you have to specify the relationship explicitly:
In the form, define a global field of the same type as the table in which the currency or quantity field is stored, for example WA_CURTAB. Also define a work area for the output of your value field, for example WA_VALTAB.
If you use a table with a header line, you do not need to define a work area. Instead, you work through the following steps with the header line of the relevant table. In the following step, for example, you would specify the field VALTAB-VALUE instead of WA_VALTAB-VALUE under Field Name.
Create the relationship to the currency field by switching to the Currency/Quantity fields of the Global Definitions node and entering the following values:
Field name: WA_VALTAB-VALUE if this is the value field of VALTAB that is to be output
Reference field: WA_CURTAB-CURRENCY, therefore the currency field of CURTAB
Use the work area WA_VALTAB on the data tab page of your table node or loop node.
Create a program lines node before the event at which the value field is printed.
In the program lines node, assign the currency or unit in which you want to format the value field WA_VALTAB-VALUE to the currency or quantity field of the global field WA_CURTAB-CURRENCY. You have to either select the value of WA_CURTAB-CURRENCY afterwards or have already passed it to the form interface.
Display or print the value field WA_VALTAB-VALUE.
Result
During output, SAP Smart Forms formats the value field WA_VALTAB-VALUE according to the value assigned to the currency or quantity field of the global variable WA_CURTAB_CURRENCY.
regards,
veeresh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.