‎2006 Nov 15 5:49 AM
‎2006 Nov 15 5:55 AM
Hi,
You want to retrieve data inside smartforms? It is not advisable to do so. Because everytime you do some changes and activate the smartform, it will delete the underlying function module and recreate. So your code will also get regenerated eventhough you havent done any or very small change. But it is possible to add your code. For doing this you select the node in which u want to write code and then right click then go to the following path. CREAE->FLOW LOGIC->PROGRAM LINES. This u can do only in change mode.
‎2006 Nov 15 5:55 AM
Hi,
You want to retrieve data inside smartforms? It is not advisable to do so. Because everytime you do some changes and activate the smartform, it will delete the underlying function module and recreate. So your code will also get regenerated eventhough you havent done any or very small change. But it is possible to add your code. For doing this you select the node in which u want to write code and then right click then go to the following path. CREAE->FLOW LOGIC->PROGRAM LINES. This u can do only in change mode.
‎2006 Nov 15 5:56 AM
Getting the function module name by form name
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'YHR_TE_CADET'
IMPORTING
fm_name = work_fm_name
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.
Calling the generated function module
CALL FUNCTION work_fm_name
EXPORTING
control_parameters = work_cont
user_settings = 'X'
general_data = wa_general
TABLES
lt_per_basic = lt_per_basic
lt_per_qual = lt_per_qual
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
'YHR_TE_CADET' - The name of your smartform.
‎2006 Nov 15 5:57 AM
hi sunil
use program line option to get the different table data by using innerjoin statement.
regards
Usman
‎2006 Nov 15 5:58 AM
hi
good
in the smartfrom when you r accessing data from the multiple internal table you have to declare all the internal table name and the fields in the form interface tab and you can use the select statement to access the data in the Type tab.
thanks
mrutyun^
‎2006 Nov 15 6:06 AM
HI..TANKS FOR UR RESPONSE..
wehre should we giv select statement either in smartformcode or in abap editor?
‎2006 Nov 15 6:11 AM
hi
in smartforms right click in particuler window then >create>program line.
in this program line like that abap editor for smartforms.
Regards
usman