on 07-22-2008 11:32 AM
I am trying to create a Smartform from scratch in a Demo SAP Netweaver installation.
Where do I define the internal tables, as I keep getting errors that WA_CUST_ADRES has either NOT been defined, or it has already been defined.
I created my own Table with Customer Data, and need to get this data into my Smartform. I seem to get stuck with this bit, as I keep on getting errors.
I hope anybody can help.
Regards
Ryno
I got it to work. thank you for your help.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
if u have a driver prog for yur smartform and want to pass it from the driver to the smartform then u need to declare the structure of the internal table in the data dictionary.
And in the smartform u declare the internal table in the form interface->tables section. u declare like this
S_JOB LIKE RNGE_OBJID
where RNGE_OBJID is a structure in data dictionary.
If u have a selectoption in driver program and need to pass to the smartform.
then do this.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = <smartform name>
IMPORTING
fm_name = v_form_fm
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
Call Smartfrom to print the document
CALL FUNCTION v_form_fm
EXPORTING
p_compensation = p_comp <--parameter list
p_skill = p_skill
p_deci_auhtority = p_da
TABLES
s_job = s_job <--select option list
s_level = s_level
s_date = s_date
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
declare the paramters of your selection screen in the form interface section of the smartform.
If you have a parameter in teh selection screen then declare it in the smartform as:
P_matnr TYPE matnr (in form interface ->import)
If you have a select option then
S_LEVEL LIKE <dictionary structure like a range>
this u declare it in the tables section of the form interface. For the select option , the dictionary sructures should be like a range (see RNGE_OBJID as an example). If you dont have a dictionary structure
then u need to declare it in the dictionary.
Also if u declare internal tables in the smartform itself
then remeber that u need to declare it in the
global definitions->global data section. eg:
I_HRP1000 TYPE X_HRP1000_T
where X_HRP1000_T is a table type declared in the
global definitions->types.
EG:
TYPES:
Job title for Job ID from table HRP1000
BEGIN OF x_hrp1000,
objid TYPE hrobjid, "Object ID
begda TYPE begdatum, "Start Date
endda TYPE enddatum, "End Date
short TYPE short_d, "Object Abbreviation
stext TYPE stext, "Object Name
END OF x_hrp1000,
Table Type
x_hrp1000_t TYPE STANDARD TABLE OF x_hrp1000 INITIAL SIZE 0.
At the initialization u need to write down all the variables, internal tbales and work areas that u use inside the initialization.
REWARD IF HELPFUL
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raino,
this links will help you how to develpe smartt forms.
http://saptechnical.com/Tutorials/Smartforms/Address/Display.htm
http://saptechnical.com/Tutorials/Smartforms/SimpleDriverProgram/Demo.htm
http://saptechnical.com/Tutorials/Smartforms/PassingData/SF.htm
http://saptechnical.com/Tutorials/Smartforms/GettingStarted/SimpleText.htm
If Found Help Full Do Reward.
Regards.
Eshwar.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.