Skip to Content
author's profile photo
Former Member

SMARTFORM interface parameter TYPEs

Hi,

I have created a TYPE-GROUP "ZCVBO", with the following types:

TYPES: BEGIN OF ZCVBO_DELIVERY_LINE,

VBELN TYPE LIKP-VBELN,

END OF ZCVBO_DELIVERY_LINE.

TYPES: ZCVBO_DELIVERIES TYPE ZCVBO_DELIVERY_LINE OCCURS 0.

TYPES: BEGIN OF ZCVBO_DATA_STRUCT,

VSTEL TYPE LIKP-VSTEL,

DELIVERIES TYPE ZCVBO_DELIVERIES,

DELIVERIES1 TYPE ZCVBO_DELIVERY_LINE occurs 0,

END OF ZCVBO_DATA_STRUCT.

But when i try to use it to declare an import parameter in my SMARTFORM, like this:

ZCVBO_DELIVERY_LINE TYPE ZCVBO_DELIVERY_LINE

I get an error like:

Form Interface The type "ZCVBO_DELIVERY_LINE"is unknown.

Can anyone help me and tell me how i can use the type i defined in my SMARTFORM interface?

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Aug 03, 2004 at 11:35 AM

    I would image that it wants to global type. Because your function module interface is public there is no way to verify if the calling program would have the same defintion for what is esentially a local type definition. Even though you put it in a type-group, the type-group declaration is local. You can just declare your types as structures and table types in the data dicitonary. That way they will be global and you won't need a type group.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Thomas,

      Thanks for the explanation. But the TYPE-POOLS declaration is only a problem with SMARTFORM. Because i have created a function module and declared the TYPPE-POOLS: ZCVBO in the top of the function module. And this allowed me to declare import parameters of the type that are in the TYPE-GROUP ZCVBO.

      I have debug the SMARTFORM and saw that SAP explicitly prevents and declaration of TYPE-POOLS in the SMARTFORM type section.

      So even if the help, says that we can use type for the FM interface if the TYPE-POOLS is declared in the function group, we can't do it for SMARTFORM. But it does work other function modules.

      thanks

  • author's profile photo
    Former Member
    Aug 10, 2004 at 04:54 AM

    Hi Vishal,

    As i understand whatever declaration u r making in the Smartform Global Data or the form interface that type should be there in the Data Dictionary and you will have to create a stryctyre of your type in SE11 and then use that in the Smartform cos even if you declare your type in the top of your function module it stays local and cannot be accessed by the Smartform.

    Hope this helps.

    Sudhi

    Add comment
    10|10000 characters needed characters exceeded