‎2007 May 14 2:54 PM
I need to pass a structure (VBLKP) into my SmartForm. Right now I have VBLKP as an import in the Form Interface. This is not working because I get a syntax error telling me that VBLKP-MATNR is not defined. Do I need to define each element in VBLKP individually in the Form Interface?
Regards,
Davis
‎2007 May 14 3:17 PM
It may be something that I am doing in the following statement (this is where the error is)
perform convert_to_pallets
using vblkp-matnr
vblkp-lfimg
vblkp-vrkme
changing w_nbrpal
w_nbrpce
w_nbrft2.In the Interface I have the following:
VBLKP type VBLKPRegards,
Davis
‎2007 May 14 3:03 PM
Hi Davis,
You don't have to define each elements. Are you sure you didn't mistye anything?
Check any SAP delivered SMARTFORMS to get some hint.
Best regards,
Peter
‎2007 May 14 3:06 PM
I don't have any SAP delivered SmartForms. We can't figure out how to get them imported into the system. We don't have Best Practices installed and it looks like that is needed to import the preconfigured SmartForms. I have checked the spelling many times and can't figure it out.
Regards,
Davis
‎2007 May 14 3:07 PM
Hi Davis,
IF you are obtaining VBLKP from the driver program then declare it in the form interface .
IF not , then declare the structure in the Global Definitions.
No need to declare the fields of the structure separately.
‎2007 May 14 3:07 PM
hi davis,
U have to declare that field..Otherwise u got the errors..I too got the same error..but i solved as i mentioned in the above method..
‎2007 May 14 3:17 PM
Hi Davis,
You can do one of the following:
1) Define a structure in your SMARTFORM interface of type VBLKP. Populate the values you need in the SMARTFORM calling program and pass the structure to the SMARTFORM via the SMARTFORM interface.
2) Populate the structure in the SMARTFORM calling program and pass it to the SAP buffer using SET PARAMETER ID pid FIELD <structure name>. In the SMARTFORM define a structure of type VBLKP in the global data or locally in the code segment (if needed only by one code segment) and use the GET PARAMETER ID pid FIELD <structure name> to get the data from SAP memory to your structure in the SMARTFORM.
Hope this helps.
Regards,
Mark
‎2007 May 14 3:17 PM
It may be something that I am doing in the following statement (this is where the error is)
perform convert_to_pallets
using vblkp-matnr
vblkp-lfimg
vblkp-vrkme
changing w_nbrpal
w_nbrpce
w_nbrft2.In the Interface I have the following:
VBLKP type VBLKPRegards,
Davis
‎2007 May 14 3:24 PM
Hey Davis,
define the formal parameters as follows:
FORM convert_to_pallets USING wp_matnr TYPE vblkp-matnr
wp_lfimg TYPE vblkp-lfimg
wp_vrkme TYPE vblkp-vrkme
CHANGING nbrpal LIKE w_nbrpal
nbrpce LIKE w_nbrpce
nbrft2 LIKE w_nbrft2.
ENDFORM. "convert_to_palletsLet me know if this helps.
Regards,
Mark