Skip to Content

Smartforms

Hello Experts,

I have created a smartform with name zform_1 and code for the same looks something like this,

REPORT ZFORM_1.

 
DATA FNAM TYPE rs38l_fnam.
DATA : DATE LIKE  SY-DATUM VALUE 'SY-DATUM',
       TCODE LIKE SY-TCODE VALUE 'SY-TCODE'.
 
 CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
   EXPORTING
     FORMNAME                 = 'ZFORM_1'
*    VARIANT                  = ' '
*    DIRECT_CALL              = ' '
*  IMPORTING
    FM_NAME                  = FNAM
  EXCEPTIONS
    NO_FORM                  = 1
    NO_FUNCTION_MODULE       = 2
    OTHERS                   = 3
           .
 IF SY-SUBRC  0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
 ENDIF.

Now my problem is when i try to call the fm 'fnam' it says it is not available.when i replaced 'fnam' with system generated function module then i got a runtime error say the parameter 'fm_name' is not defined.

what can i do to solve this problem.Any kind of help or suggestion will be appreciated.

Regards

Abhinab

<MOVED BY MODERATOR TO THE CORRECT FORUM>

<LOCKED BY MODERATOR - USE APPROPRIATE TITLES>

Edited by: Alvaro Tejada Galindo on Dec 23, 2008 10:13 AM

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Dec 23, 2008 at 12:37 PM

    hi,

    please follow the following steps.

    1. Goto SMARTFORMS transaction and give the form name and press execute button.

    2. SE37 window will be dipslayed with FM name EX: /1BCDWB/SF00000109

    3. Copy the Fm name and Go to the report when you want to call the smartfrom and Using Patters(Ctrl+F6) button call the FM by pasting the copied name.

    4. now replace the FM /1BCDWB/SF00000109 with FNAM.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 23, 2008 at 12:40 PM

    hi

    remove the quotes in the form name and try FORMNAME = 'ZFORM_1'

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 23, 2008 at 12:52 PM

    Hi Abhinab,

    Just uncomment the line IMPORTING

    It will work fine.

    Regards,

    Nitin.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.