‎2006 Aug 23 12:08 PM
hi everybody
my problem is like this
after activating my smartform i got a functional module
'/1BCDWB/SF00000108' and i passed this functional module to LF_FMNAME. but when i tried to call this functional module going to pattern and give the name of FM like LF_FMNAME i am getting message like FM not found.
could u plz how to correct this error.
i wrote the following code.
DATA:BEGIN OF GT_EQUI OCCURS 0,
EQUNR LIKE EQUI-EQUNR,
END OF GT_EQUI.
DATA:LF_FMNAME TYPE RS38L_FNAM VALUE '/1BCDWB/SF00000108'.
PARAMETERS: p_equnr TYPE equi-equnr
SELECT EQUNR
FROM EQUI
INTO TABLE GT_EQUI
WHERE EQUNR EQ p_EQUNR.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = 'ZSAMPLE1'
IMPORTING
FM_NAME = LF_FMNAME
regards
hridhayanjili.
‎2006 Aug 23 12:12 PM
Do not use pattern function.
DATA:BEGIN OF GT_EQUI OCCURS 0,
EQUNR LIKE EQUI-EQUNR,
END OF GT_EQUI.
DATA:LF_FMNAME TYPE RS38L_FNAM VALUE '/1BCDWB/SF00000108'.
PARAMETERS: p_equnr TYPE equi-equnr
SELECT EQUNR
FROM EQUI
INTO TABLE GT_EQUI
WHERE EQUNR EQ p_EQUNR.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = 'ZSAMPLE1'
IMPORTING
FM_NAME = LF_FMNAME.
call function LF_FMNAME
exporting....
importing..
tables..
Regards,
Ravi
‎2006 Aug 23 12:13 PM
Hi.
Please dont pass any value to LF_FNAME.
The function will itself assign it the value.
Use it like this.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = p_sfname
IMPORTING
fm_name = LF_FNAME
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
where, p_sfname id the forms name
and LF_FNAMe is the returning function name.
Regards,
Amit
‎2006 Aug 23 12:14 PM
Is ZSAMPLE1 the name of your smartform?
Also, it is not necessary to specify a value on your lf_fmname variable. This value is determined by the function module.
The function module name will be generated in each SAP environment so it is not guaranteed to be '/1BCDWB/SF00000108' in every system.
‎2006 Aug 23 12:14 PM
Hello,
U have use like this.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
FORMNAME = 'ZSAMPLE1'
IMPORTING
FM_NAME = LF_FMNAME
Then
<b>CALL FUNCTION LF_FMNAME
EXPORTING
.....
IMPORTING
.......</b>
If useful reward.
Vasanth
‎2006 Aug 23 12:28 PM