on 08-30-2007 6:37 AM
hi all
i want to pass two internal tables to my smart form
i give the folowing code in the globel definition TYPES
types: begin of st_itab1,
mblnr like mkpf-mblnr,
bldat like mkpf-bldat, "document date
mjahr like mkpf-mjahr, "document year
budat like mkpf-budat, "posting date
end of st_itab1.
types: begin of st_itab2,
mblnr like mseg-mblnr,
mjahr like mseg-mblnr,
bwart like mseg-bwart,
matnr like mseg-matnr,
menge like mseg-menge,
meins like mseg-meins,
end of st_itab2.
and in form interface i wrote in TABLES:
IATB4 TYPE ST_ITAB1
ITAB5 TYPE ST_ITAB2.
i hav not used these tables in the smart form
but when i activate this form
the following error comes
Form Interface: Only table types may be used as the reference type
PLZ HELP
As far as my knowledge goes you have to create a structure. While activating it will search for its associated type in DDIC. Without creating structures I don't know whether its possible or not. But after creating structures I have got my output.
Regards,
mallick
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
1) Are you using any driver program to call this smartforms. if so , the structure of the internal table should be created as structure in database, otherwise smartforms won't recognize it. Don't declare anything in types tab. don't put anything under global data.
delete the code you have written earlier.
2) if there is no driver program to pass data's to smartforms. Don't declare anything on table tab. and write whatever I wrote in global declaration there.
The error is due to the fact that in tables tab your internal table is of your customized type which the smartforms does not understand. It refers to data dictionary, there it does not find any such structure. So it displays the error.
Regards,
mallick
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You use table tab under global declaration to pass internal tables from driver program to smartforms. Here you have to create a structure using se11 containing the fields and in the reference field instead of writing st_itab1 give the name of the structure created. types is used for making structures local to the smartforms. You have to declare it again in global declarations the tables or structures that has the same structure as that of the typed structure. In case you are not using driver program don't write it under tables.
rather in global declaration write
st_itab3 type st_itab1 (for declaring work area)
st_itab4 type table of st_itab1 ( for declaring the table).
Similarly do the same for type st_itab2.
Reg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
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.