Monday 6 April 2015

5.Smartfrom : How to call a Smartform Progrmatically?


-----------------------------------------------------------------------------------------------------------------------------------
Step1. So here we have a smartform 'ZSM_FOUR' . Every smartform is associated with function module. To call a smartform programatically, it is enough to call the respective function module from the program. From the Environment menu find the smartform function module name.



Step2. Create a program in Tx- SE38 and call the relevant function module of the smartform.




Step3. Activate the program and execute it.



Step4. As the report output, click on the print preview option.



Step5. So we have the smartform output generated by calling the function module of the smartform from the program. But it is not a good way of calling the smartform by calling the function module. 
In the development System- Smartform is created and it automatically generates a function module and in the report we call this function module.

When the smartform is moved to a quality or production system, it might generate a different function module and if the same report is used in the quality or production system to call the smartform, sometime it might generate error.

See the next post to know how a smartform is called exactly?




--------------------------------------------------------------------------------------------------------------------------------------

No comments:

Comments system

Disqus Shortname