<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: sap smartforms in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747576#M901705</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;just try step by step and learn ,you cannot learn at a single go ,&lt;/P&gt;&lt;P&gt;try doing it several times you can easily learn it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Advantages of SAP Smart Forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP Smart Forms have the following advantages: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. The adaption of forms is supported to a large extent by graphic tools for layout and logic, so that no programming knowledge is necessary (at least 90% of all adjustments). Therefore, power user forms can also make configurations for your business processes with data from an SAP system. Consultants are only required in special cases. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Displaying table structures (dynamic framing of texts) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. Output of background graphics, for form design in particular the use of templates which were scanned. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. Colored output of texts &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5. User-friendly and integrated Form Painter for the graphical design of forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;6. Graphical Table Painter for drawing tables &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;7. Reusing Font and paragraph formats in forms (Smart Styles) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;8. Data interface in XML format (XML for Smart Forms, in short XSF) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;9. Form translation is supported by standard translation tools &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;10. Flexible reuse of text modules &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;11. HTML output of forms (Basis release 6.10) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;12. Interactive Web forms with input fields, pushbuttons, radio buttons, etc. (Basis-Release 6.10) &lt;/P&gt;&lt;P&gt;A Simple Smartform Tutorial &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP Smartforms can be used for creating and maintaining forms for mass printing in SAP Systems. The output medium for Smartforms support printer, fax, e-mail, or the Internet (by using the generated XML output). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;According to SAP, you need neither have any programming knowledge nor use a Script language to adapt standard forms. However, basic ABAP programming skills are required only in special cases (for example, to call a function module you created or for complex and extensive conditions). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Create a new smartforms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction code SMARTFORMS &lt;/P&gt;&lt;P&gt;Create new smartforms call ZSMART&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Define looping process for internal table &lt;/P&gt;&lt;P&gt;Pages and windows &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First Page -&amp;gt; Header Window (Cursor at First Page then click Edit -&amp;gt; Node -&amp;gt; Create) &lt;/P&gt;&lt;P&gt;Here, you can specify your title and page numbering &lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGE&amp;amp; (Page 1) of &amp;amp;SFSY-FORMPAGES(Z4.0)&amp;amp; (Total Page) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Main windows -&amp;gt; TABLE -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the Loop section, tick Internal table and fill in &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. Define table in smartforms &lt;/P&gt;&lt;P&gt;Global settings : &lt;/P&gt;&lt;P&gt;Form interface &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB1 TYPE Table Structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Global definitions &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB2 TYPE Table Structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. To display the data in the form &lt;/P&gt;&lt;P&gt;Make used of the Table Painter and declare the Line Type in Tabstrips Table &lt;/P&gt;&lt;P&gt;e.g. HD_GEN for printing header details, &lt;/P&gt;&lt;P&gt;IT_GEN for printing data details. &lt;/P&gt;&lt;P&gt;You have to specify the Line Type in your Text elements in the Tabstrips Output options. &lt;/P&gt;&lt;P&gt;Tick the New Line and specify the Line Type for outputting the data. &lt;/P&gt;&lt;P&gt;Declare your output fields in Text elements &lt;/P&gt;&lt;P&gt;Tabstrips - Output Options &lt;/P&gt;&lt;P&gt;For different fonts use this Style : IDWTCERTSTYLE &lt;/P&gt;&lt;P&gt;For Quantity or Amout you can used this variable &amp;amp;GS_ITAB-AMOUNT(12.2)&amp;amp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5. Calling SMARTFORMS from your ABAP program &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT ZSMARTFORM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Calling SMARTFORMS from your ABAP program. &lt;/P&gt;&lt;P&gt;Collecting all the table data in your program, and pass once to SMARTFORMS &lt;/P&gt;&lt;P&gt;SMARTFORMS &lt;/P&gt;&lt;P&gt;Declare your table type in :- &lt;/P&gt;&lt;P&gt;Global Settings -&amp;gt; Form Interface &lt;/P&gt;&lt;P&gt;Global Definintions -&amp;gt; Global Data &lt;/P&gt;&lt;P&gt;Main Window -&amp;gt; Table -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming &lt;/P&gt;&lt;P&gt;&lt;A href="http://sapr3.tripod.com" target="test_blank"&gt;http://sapr3.tripod.com&lt;/A&gt; &lt;/P&gt;&lt;P&gt;TABLES: MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: FM_NAME TYPE RS38L_FNAM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF INT_MKPF OCCURS 0. &lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE MKPF. &lt;/P&gt;&lt;P&gt;DATA: END OF INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR. &lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING MKPF TO INT_MKPF. &lt;/P&gt;&lt;P&gt;APPEND INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDSELECT. &lt;/P&gt;&lt;P&gt;At the end of your program. &lt;/P&gt;&lt;P&gt;Passing data to SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function 'SSF_FUNCTION_MODULE_NAME' &lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;formname = 'ZSMARTFORM' &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;VARIANT = ' ' &lt;/P&gt;&lt;P&gt;DIRECT_CALL = ' ' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;FM_NAME = FM_NAME &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;NO_FORM = 1 &lt;/P&gt;&lt;P&gt;NO_FUNCTION_MODULE = 2 &lt;/P&gt;&lt;P&gt;OTHERS = 3. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;WRITE: / 'ERROR 1'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function FM_NAME &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EXPORTING &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX = &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX_TAB = &lt;/P&gt;&lt;P&gt;ARCHIVE_PARAMETERS = &lt;/P&gt;&lt;P&gt;CONTROL_PARAMETERS = &lt;/P&gt;&lt;P&gt;MAIL_APPL_OBJ = &lt;/P&gt;&lt;P&gt;MAIL_RECIPIENT = &lt;/P&gt;&lt;P&gt;MAIL_SENDER = &lt;/P&gt;&lt;P&gt;OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;USER_SETTINGS = 'X' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;DOCUMENT_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;TABLES &lt;/P&gt;&lt;P&gt;GS_MKPF = INT_MKPF &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;FORMATTING_ERROR = 1 &lt;/P&gt;&lt;P&gt;INTERNAL_ERROR = 2 &lt;/P&gt;&lt;P&gt;SEND_ERROR = 3 &lt;/P&gt;&lt;P&gt;USER_CANCELED = 4 &lt;/P&gt;&lt;P&gt;OTHERS = 5. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;________________________________________&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Additional Fonts for your SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can create additional fonts and style with transaction SMARTSTYLES &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This can then be define in the paragraph and character formats, which you can then be assign to texts and fields in the Smart Form. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The character formats includes effects such as superscript, subscript, barcode and font attributes. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Difference with SMARTFORMS vs. SapScript(SE71) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Following are the differences :- &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a) Multiple page formats are possible in smartforms which is not the case in SAPScripts &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;b) It is possible to have a smartform without a main window . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;c) Labels cannot be created in smartforms. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;d) Routines can be written in smartforms tool. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;e) Smartforms generates a function module when activated. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;f) Unlike sapscripts (RSTXSCRP), you cannot upload/download Smartform to your local harddisk. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It was said that it was provided in CRM 3.0 version, but not available in R/3. You can download smartforms into Local PC in a XML format. In the same way you can upload this XML format into Smartform. From the smartform editor itself you can call download option, if you are working in CRM 3.0 environment. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In R3 also, you can download into XML format. However, it's not sure about uploading. Refer to the program 'SF_XSF_DEMO'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In 4.7 Enterprise, other have seen this utlity which is completey missing in 4.6c. There is functionality to downlaod a complete form or only a particular node. (Utilities -&amp;gt; Download form). It will create a XML file and save it in the hard disk. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For others, if you want to download/upload the Smartforms source, you will need the help from the Basis people. What you can do is to create a Transport and then FTP down to your local harddisk. When you need the Smartform source in another system, you have FTP up the Smartforms file back to the SAP server. Finally, the Basis team, will tp it into your system. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;g) The protect and endprotect command in sapscript doesn't work with smartforms. For example on a invoice: First data of position no 80. is printed on page one, other data of position no 80 is printed on page 2. And there's nothing you can do about it. Actually, there is something you can do about it. By using a folder node and checking the 'protect' checkbox, everything in that folder will be page protected. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FAQ on Migrating SAPscript to SmartForms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to migrate a SAPscript form to a Smart Form? &lt;/P&gt;&lt;P&gt;Smart Forms provides a migration tool for this purpose which migrates layout and texts of a SAPscript form to a Smart Form. It does not migrate SAPscript form logic of the print program. Using Smart Forms, this logic is described by the tree structure of the Form Builder. The effort involved in migrating it depends on the complexity of the print program. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Which Basis Release do I need to use SAP Smart Forms? &lt;/P&gt;&lt;P&gt;SAP Smart Forms is available as of R/3 Basis Release 4.6C. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have heard that Smart Forms replaces SAPscript. What does "replace" mean? &lt;/P&gt;&lt;P&gt;It does not mean that SAPscript is removed from the Basis shipment. Even as of Basis Release 4.6C, SAPscript remains part of the SAP standard and there are no plans to remove it. Since Smart Forms is currently, and will continue to be, the tool for form maintenance for mySAP.com solutions, our further development efforts will focus on Smart Forms, not on SAPscript. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do we have to migrate all SAPscript forms to Smart Forms? &lt;/P&gt;&lt;P&gt;There is no point in migrating all SAPscript forms already in use. Since SAPscript can still be used and will be available in the future, there is no need to. If you plan to migrate a SAPscript form, it is recommended that you check whether benefit is worth the effort involved. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Conversion of SAPSCRIPT to SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP provides a conversion for SAPscript documents to SMARTforms. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is basically a function module, called FB_MIGRATE_FORM. You can start this function module by hand (via SE37), or create a small ABAP which migrates all SAPscript forms automatically. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also do this one-by-one in transaction SMARTFORMS, under &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Utilities -&amp;gt; Migrate SAPscript form. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You could also write a small batch program calling transaction SMARTFORMS and running the migration tool. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SmartForms System Fields &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Within a form you can use the field string SFSY with its system fields. During form processing the system replaces these fields with the corresponding values. The field values come from the SAP System or are results of the processing. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;System fields of Smart Forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-DATE&amp;amp; &lt;/P&gt;&lt;P&gt;Displays the date. You determine the display format in the user master record. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-TIME&amp;amp; &lt;/P&gt;&lt;P&gt;Displays the time of day in the form HH:MM:SS. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGE&amp;amp; &lt;/P&gt;&lt;P&gt;Inserts the number of the current print page into the text. You determine the format of the page number (for example, Arabic, numeric) in the page node. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-FORMPAGES&amp;amp; &lt;/P&gt;&lt;P&gt;Displays the total number of pages for the currently processed form. This allows you to include texts such as'Page x of y' into your output. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-JOBPAGES&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the total page number of all forms in the currently processed print request. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-WINDOWNAME&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the name of the current window (string in the Window field) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGENAME&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the name of the current page (string in the Page field) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGEBREAK&amp;amp; &lt;/P&gt;&lt;P&gt;Is set to 'X' after a page break (either automatic Page 7 or command-controlled Page 46) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-MAINEND&amp;amp; &lt;/P&gt;&lt;P&gt;Is set as soon as processing of the main window on the current page ends &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-EXCEPTION&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the name of the raised exception. You must trigger your own exceptions, which you defined in the form interface, using the user_exception macro (syntax: user_exception &amp;lt;exception name &amp;gt;). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example Forms Available in Standard SAP R/3 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SF_EXAMPLE_01 &lt;/P&gt;&lt;P&gt;Simple example; invoice with table output of flight booking for one customer &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SF_EXAMPLE_02 &lt;/P&gt;&lt;P&gt;Similar to SF_EXAMPLE_01 but with subtotals &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SF_EXAMPLE_03 &lt;/P&gt;&lt;P&gt;Similar to SF_EXAMPLE_02, whereby several customers are selected in the application program; the form is called for each customer and all form outputs are included in an output request &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Smart forms Frequently Asked Questions &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Forcing a page break within table loop &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Create a loop around the table. Put a Command node before the table in the loop that forces a NEWPAGE on whatever condition you want. Then only loop through a subset of the internal table (based on the conditions in the Command node) of the elements in the Table node. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Font style and Font size &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Goto Transaction SMARTSTYLES. &lt;/P&gt;&lt;P&gt;There you can create Paragraph formats etc just like in sapscript. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then in your window under OUTPUT OPTIONS you include this SMARTSTYLE and use the Paragraph and character formats. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Line in Smartform &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Either you can use a window that takes up the width of your page and only has a height of 1 mm. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then you put a frame around it (in window output options). &lt;/P&gt;&lt;P&gt;Thus you have drawn a box but it looks like a line. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or you can just draw "__" accross the page and play with the fonts so that it joins each UNDER_SCORE. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Difference between 'forminterface' and 'global definitions' in global settings of smart forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Difference is as follows. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To put it very simply: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Form Interface is where you declare what must be passed in and out of the smartform (in from the print program to the smartform and out from the smartform to the print program). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Global defs. is where you declare data to be used within the smartform on a global scope. &lt;/P&gt;&lt;P&gt;ie: anything you declare here can be used in any other node in the form. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Smartforms function module name &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once you have activated the smartform, go to the environment -&amp;gt; function module name. There you can get the name of funtion module name. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The key thing is the program that calls it. for instance, the invoice SMARTFORM LB_BIL_INVOICE is ran by the program RLB_INVOICE. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This program uses another FM to determine the name of the FM to use itself. The key thing is that when it calls this FM (using a variable to store the actual name), that the parameters match the paramters in your smartform. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another thing to note is that the FM name will change wherever the SF is transported to. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So you need to use the FM to determine the name of the SF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the code that can be use to determine the internal name of the function module: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sf_label(1) '/'. " need to resolve by name &lt;/P&gt;&lt;P&gt;move sf_label to externalname. &lt;/P&gt;&lt;P&gt;call function 'SSF_FUNCTION_MODULE_NAME' &lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;formname = externalname &lt;/P&gt;&lt;P&gt;importing &lt;/P&gt;&lt;P&gt;fm_name = internalname &lt;/P&gt;&lt;P&gt;exceptions &lt;/P&gt;&lt;P&gt;no_form = 1 &lt;/P&gt;&lt;P&gt;no_function_module = 2 &lt;/P&gt;&lt;P&gt;others = 3. &lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;message 'e427'. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;move internalname to sf_label. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It checks to see if the sf_label starts with a '/', which is how the internal names start. if it does, the name has already been converted. If not, it calls the FM and converts the name&lt;/P&gt;&lt;P&gt;one more example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Create a new smartforms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction code SMARTFORMS &lt;/P&gt;&lt;P&gt;Create new smartforms call ZSMART&lt;/P&gt;&lt;P&gt;2. Define looping process for internal table &lt;/P&gt;&lt;P&gt;Pages and windows &lt;/P&gt;&lt;P&gt;First Page -&amp;gt; Header Window (Cursor at First Page then click Edit -&amp;gt; Node -&amp;gt; Create) &lt;/P&gt;&lt;P&gt;Here, you can specify your title and page numbering &lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGE&amp;amp; (Page 1) of &amp;amp;SFSY-FORMPAGES(Z4.0)&amp;amp; (Total Page) &lt;/P&gt;&lt;P&gt;Main windows -&amp;gt; TABLE -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;In the Loop section, tick Internal table and fill in &lt;/P&gt;&lt;P&gt;ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2 &lt;/P&gt;&lt;P&gt;3. Define table in smartforms &lt;/P&gt;&lt;P&gt;Global settings : &lt;/P&gt;&lt;P&gt;Form interface &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB1 TYPE Table Structure &lt;/P&gt;&lt;P&gt;Global definitions &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB2 TYPE Table Structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. To display the data in the form &lt;/P&gt;&lt;P&gt;Make used of the Table Painter and declare the Line Type in Tabstrips Table &lt;/P&gt;&lt;P&gt;e.g. HD_GEN for printing header details, &lt;/P&gt;&lt;P&gt;IT_GEN for printing data details. &lt;/P&gt;&lt;P&gt;You have to specify the Line Type in your Text elements in the Tabstrips Output options. &lt;/P&gt;&lt;P&gt;Tick the New Line and specify the Line Type for outputting the data. &lt;/P&gt;&lt;P&gt;Declare your output fields in Text elements &lt;/P&gt;&lt;P&gt;Tabstrips - Output Options &lt;/P&gt;&lt;P&gt;For different fonts use this Style : IDWTCERTSTYLE &lt;/P&gt;&lt;P&gt;For Quantity or Amout you can used this variable &amp;amp;GS_ITAB-AMOUNT(12.2)&amp;amp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5. Calling SMARTFORMS from your ABAP program &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT ZSMARTFORM. &lt;/P&gt;&lt;P&gt;Calling SMARTFORMS from your ABAP program. &lt;/P&gt;&lt;P&gt;Collecting all the table data in your program, and pass once to SMARTFORMS &lt;/P&gt;&lt;P&gt;SMARTFORMS &lt;/P&gt;&lt;P&gt;Declare your table type in :- &lt;/P&gt;&lt;P&gt;Global Settings -&amp;gt; Form Interface &lt;/P&gt;&lt;P&gt;Global Definintions -&amp;gt; Global Data &lt;/P&gt;&lt;P&gt;Main Window -&amp;gt; Table -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming &lt;/P&gt;&lt;P&gt;&lt;A href="http://sapr3.tripod.com" target="test_blank"&gt;http://sapr3.tripod.com&lt;/A&gt; &lt;/P&gt;&lt;P&gt;TABLES: MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: FM_NAME TYPE RS38L_FNAM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF INT_MKPF OCCURS 0. &lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE MKPF. &lt;/P&gt;&lt;P&gt;DATA: END OF INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR. &lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING MKPF TO INT_MKPF. &lt;/P&gt;&lt;P&gt;APPEND INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDSELECT. &lt;/P&gt;&lt;P&gt;At the end of your program. &lt;/P&gt;&lt;P&gt;Passing data to SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function 'SSF_FUNCTION_MODULE_NAME' &lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;formname = 'ZSMARTFORM' &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;VARIANT = ' ' &lt;/P&gt;&lt;P&gt;DIRECT_CALL = ' ' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;FM_NAME = FM_NAME &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;NO_FORM = 1 &lt;/P&gt;&lt;P&gt;NO_FUNCTION_MODULE = 2 &lt;/P&gt;&lt;P&gt;OTHERS = 3. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;WRITE: / 'ERROR 1'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function FM_NAME &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EXPORTING &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX = &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX_TAB = &lt;/P&gt;&lt;P&gt;ARCHIVE_PARAMETERS = &lt;/P&gt;&lt;P&gt;CONTROL_PARAMETERS = &lt;/P&gt;&lt;P&gt;MAIL_APPL_OBJ = &lt;/P&gt;&lt;P&gt;MAIL_RECIPIENT = &lt;/P&gt;&lt;P&gt;MAIL_SENDER = &lt;/P&gt;&lt;P&gt;OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;USER_SETTINGS = 'X' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;DOCUMENT_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;TABLES &lt;/P&gt;&lt;P&gt;GS_MKPF = INT_MKPF &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;FORMATTING_ERROR = 1 &lt;/P&gt;&lt;P&gt;INTERNAL_ERROR = 2 &lt;/P&gt;&lt;P&gt;SEND_ERROR = 3 &lt;/P&gt;&lt;P&gt;USER_CANCELED = 4 &lt;/P&gt;&lt;P&gt;OTHERS = 5. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;also check &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check these links.In this,I am explaining everything step-by-step.Kindly reward points by clikcing the star on the left of reply,if it is useful.&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/ccab6730-0501-0010-ee84-de050a6cc287" target="test_blank"&gt;https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/ccab6730-0501-0010-ee84-de050a6cc287&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/8fd773b3-0301-0010-eabe-82149bcc292e" target="test_blank"&gt;https://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/8fd773b3-0301-0010-eabe-82149bcc292e&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/3c5d9ae3-0501-0010-0090-bdfb2d458985" target="test_blank"&gt;https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/3c5d9ae3-0501-0010-0090-bdfb2d458985&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check these links also.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-basis-abap.com/sapsf001.htm" target="test_blank"&gt;http://www.sap-basis-abap.com/sapsf001.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-press.com/downloads/h955_preview.pdf" target="test_blank"&gt;http://www.sap-press.com/downloads/h955_preview.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.ossincorp.com/Black_Box/Black_Box_2.htm" target="test_blank"&gt;http://www.ossincorp.com/Black_Box/Black_Box_2.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-img.com/smartforms/sap-smart-forms.htm" target="test_blank"&gt;http://www.sap-img.com/smartforms/sap-smart-forms.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-img.com/smartforms/smartform-tutorial.htm" target="test_blank"&gt;http://www.sap-img.com/smartforms/smartform-tutorial.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sapgenie.com/abap/smartforms.htm" target="test_blank"&gt;http://www.sapgenie.com/abap/smartforms.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;hope this information is helpful...&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thnx&lt;/P&gt;&lt;P&gt;sravani&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;PLZ REWARD IF HELPFUL....&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 30 Apr 2008 09:25:52 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-04-30T09:25:52Z</dc:date>
    <item>
      <title>sap smartforms</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747573#M901702</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI all , &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls send me the detailed information on sap smartforms&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Apr 2008 07:41:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747573#M901702</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-30T07:41:23Z</dc:date>
    </item>
    <item>
      <title>Re: sap smartforms</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747574#M901703</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Smart Form PDF Link:&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVSCRSF/BCSRVSCRSF.pdf" target="test_blank"&gt;http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVSCRSF/BCSRVSCRSF.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also have a look at below links:&lt;/P&gt;&lt;P&gt;&lt;A href="http://sap.ionelburlacu.ro/sap0/sapsf001.htm" target="test_blank"&gt;http://sap.ionelburlacu.ro/sap0/sapsf001.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_erp2004/helpdata/en/a9/de6838abce021ae10000009b38f842/frameset.htm" target="test_blank"&gt;http://help.sap.com/saphelp_erp2004/helpdata/en/a9/de6838abce021ae10000009b38f842/frameset.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04s/helpdata/en/a5/de6838abce021ae10000009b38f842/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04s/helpdata/en/a5/de6838abce021ae10000009b38f842/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw2004s/helpdata/en/16/a369b1800e4bdda978ee0fe3b7bd2c/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw2004s/helpdata/en/16/a369b1800e4bdda978ee0fe3b7bd2c/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://help.sap.com/saphelp_nw04s/helpdata/en/a5/de6838abce021ae10000009b38f842/content.htm" target="test_blank"&gt;http://help.sap.com/saphelp_nw04s/helpdata/en/a5/de6838abce021ae10000009b38f842/content.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-basis-abap.com/sapsf001.htm" target="test_blank"&gt;http://www.sap-basis-abap.com/sapsf001.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-img.com/smartforms/smart-001.htm" target="test_blank"&gt;http://www.sap-img.com/smartforms/smart-001.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Vibha &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please mark all the helpful answers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Apr 2008 07:44:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747574#M901703</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-30T07:44:04Z</dc:date>
    </item>
    <item>
      <title>Re: sap smartforms</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747575#M901704</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Smartforms tutorial&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/7e67af5c-6188-4252-8613-41816756d560/from-sappres.pdf" target="test_blank"&gt;http://esnips.com/doc/7e67af5c-6188-4252-8613-41816756d560/from-sappres.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/58566115-54a4-4405-8872-8de952e245e5/smartform.pdf" target="test_blank"&gt;http://esnips.com/doc/58566115-54a4-4405-8872-8de952e245e5/smartform.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/13b7ae7a-b32c-4b96-b588-881859d4ac99/Template,Table,Loop,Command-in-Smartforms.doc" target="test_blank"&gt;http://esnips.com/doc/13b7ae7a-b32c-4b96-b588-881859d4ac99/Template,Table,Loop,Command-in-Smartforms.doc&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/97acb00a-e513-4611-91f0-c626f460bfc5/Smart_Form_Overview.pdf" target="test_blank"&gt;http://esnips.com/doc/97acb00a-e513-4611-91f0-c626f460bfc5/Smart_Form_Overview.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/77a981b9-8fe3-4fbb-8101-67745c1fe60c/SMART-FORMS_shail.ppt" target="test_blank"&gt;http://esnips.com/doc/77a981b9-8fe3-4fbb-8101-67745c1fe60c/SMART-FORMS_shail.ppt&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/8810a29f-f13d-4ec8-ae90-3342e50fdd53/smartform-tutorial.pdf" target="test_blank"&gt;http://esnips.com/doc/8810a29f-f13d-4ec8-ae90-3342e50fdd53/smartform-tutorial.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/e5543612-b210-4f77-9673-19b5f58f9385/subroutine-and-select-options.pdf" target="test_blank"&gt;http://esnips.com/doc/e5543612-b210-4f77-9673-19b5f58f9385/subroutine-and-select-options.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://esnips.com/doc/7660eaed-d332-4844-a98c-8d295def6f57/sform-in-ABAP.pdf" target="test_blank"&gt;http://esnips.com/doc/7660eaed-d332-4844-a98c-8d295def6f57/sform-in-ABAP.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For step by step tutorial with screen shots....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.saptechnical.com/Tutorials/Smartforms/SFMain.htm" target="test_blank"&gt;http://www.saptechnical.com/Tutorials/Smartforms/SFMain.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Hope this helps, Do reward.&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Apr 2008 09:20:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747575#M901704</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-30T09:20:42Z</dc:date>
    </item>
    <item>
      <title>Re: sap smartforms</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747576#M901705</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;just try step by step and learn ,you cannot learn at a single go ,&lt;/P&gt;&lt;P&gt;try doing it several times you can easily learn it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Advantages of SAP Smart Forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP Smart Forms have the following advantages: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. The adaption of forms is supported to a large extent by graphic tools for layout and logic, so that no programming knowledge is necessary (at least 90% of all adjustments). Therefore, power user forms can also make configurations for your business processes with data from an SAP system. Consultants are only required in special cases. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Displaying table structures (dynamic framing of texts) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. Output of background graphics, for form design in particular the use of templates which were scanned. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. Colored output of texts &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5. User-friendly and integrated Form Painter for the graphical design of forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;6. Graphical Table Painter for drawing tables &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;7. Reusing Font and paragraph formats in forms (Smart Styles) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;8. Data interface in XML format (XML for Smart Forms, in short XSF) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;9. Form translation is supported by standard translation tools &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;10. Flexible reuse of text modules &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;11. HTML output of forms (Basis release 6.10) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;12. Interactive Web forms with input fields, pushbuttons, radio buttons, etc. (Basis-Release 6.10) &lt;/P&gt;&lt;P&gt;A Simple Smartform Tutorial &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP Smartforms can be used for creating and maintaining forms for mass printing in SAP Systems. The output medium for Smartforms support printer, fax, e-mail, or the Internet (by using the generated XML output). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;According to SAP, you need neither have any programming knowledge nor use a Script language to adapt standard forms. However, basic ABAP programming skills are required only in special cases (for example, to call a function module you created or for complex and extensive conditions). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Create a new smartforms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction code SMARTFORMS &lt;/P&gt;&lt;P&gt;Create new smartforms call ZSMART&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Define looping process for internal table &lt;/P&gt;&lt;P&gt;Pages and windows &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First Page -&amp;gt; Header Window (Cursor at First Page then click Edit -&amp;gt; Node -&amp;gt; Create) &lt;/P&gt;&lt;P&gt;Here, you can specify your title and page numbering &lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGE&amp;amp; (Page 1) of &amp;amp;SFSY-FORMPAGES(Z4.0)&amp;amp; (Total Page) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Main windows -&amp;gt; TABLE -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the Loop section, tick Internal table and fill in &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;3. Define table in smartforms &lt;/P&gt;&lt;P&gt;Global settings : &lt;/P&gt;&lt;P&gt;Form interface &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB1 TYPE Table Structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Global definitions &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB2 TYPE Table Structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. To display the data in the form &lt;/P&gt;&lt;P&gt;Make used of the Table Painter and declare the Line Type in Tabstrips Table &lt;/P&gt;&lt;P&gt;e.g. HD_GEN for printing header details, &lt;/P&gt;&lt;P&gt;IT_GEN for printing data details. &lt;/P&gt;&lt;P&gt;You have to specify the Line Type in your Text elements in the Tabstrips Output options. &lt;/P&gt;&lt;P&gt;Tick the New Line and specify the Line Type for outputting the data. &lt;/P&gt;&lt;P&gt;Declare your output fields in Text elements &lt;/P&gt;&lt;P&gt;Tabstrips - Output Options &lt;/P&gt;&lt;P&gt;For different fonts use this Style : IDWTCERTSTYLE &lt;/P&gt;&lt;P&gt;For Quantity or Amout you can used this variable &amp;amp;GS_ITAB-AMOUNT(12.2)&amp;amp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5. Calling SMARTFORMS from your ABAP program &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT ZSMARTFORM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Calling SMARTFORMS from your ABAP program. &lt;/P&gt;&lt;P&gt;Collecting all the table data in your program, and pass once to SMARTFORMS &lt;/P&gt;&lt;P&gt;SMARTFORMS &lt;/P&gt;&lt;P&gt;Declare your table type in :- &lt;/P&gt;&lt;P&gt;Global Settings -&amp;gt; Form Interface &lt;/P&gt;&lt;P&gt;Global Definintions -&amp;gt; Global Data &lt;/P&gt;&lt;P&gt;Main Window -&amp;gt; Table -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming &lt;/P&gt;&lt;P&gt;&lt;A href="http://sapr3.tripod.com" target="test_blank"&gt;http://sapr3.tripod.com&lt;/A&gt; &lt;/P&gt;&lt;P&gt;TABLES: MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: FM_NAME TYPE RS38L_FNAM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF INT_MKPF OCCURS 0. &lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE MKPF. &lt;/P&gt;&lt;P&gt;DATA: END OF INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR. &lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING MKPF TO INT_MKPF. &lt;/P&gt;&lt;P&gt;APPEND INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDSELECT. &lt;/P&gt;&lt;P&gt;At the end of your program. &lt;/P&gt;&lt;P&gt;Passing data to SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function 'SSF_FUNCTION_MODULE_NAME' &lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;formname = 'ZSMARTFORM' &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;VARIANT = ' ' &lt;/P&gt;&lt;P&gt;DIRECT_CALL = ' ' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;FM_NAME = FM_NAME &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;NO_FORM = 1 &lt;/P&gt;&lt;P&gt;NO_FUNCTION_MODULE = 2 &lt;/P&gt;&lt;P&gt;OTHERS = 3. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;WRITE: / 'ERROR 1'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function FM_NAME &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EXPORTING &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX = &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX_TAB = &lt;/P&gt;&lt;P&gt;ARCHIVE_PARAMETERS = &lt;/P&gt;&lt;P&gt;CONTROL_PARAMETERS = &lt;/P&gt;&lt;P&gt;MAIL_APPL_OBJ = &lt;/P&gt;&lt;P&gt;MAIL_RECIPIENT = &lt;/P&gt;&lt;P&gt;MAIL_SENDER = &lt;/P&gt;&lt;P&gt;OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;USER_SETTINGS = 'X' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;DOCUMENT_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;TABLES &lt;/P&gt;&lt;P&gt;GS_MKPF = INT_MKPF &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;FORMATTING_ERROR = 1 &lt;/P&gt;&lt;P&gt;INTERNAL_ERROR = 2 &lt;/P&gt;&lt;P&gt;SEND_ERROR = 3 &lt;/P&gt;&lt;P&gt;USER_CANCELED = 4 &lt;/P&gt;&lt;P&gt;OTHERS = 5. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;________________________________________&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Additional Fonts for your SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can create additional fonts and style with transaction SMARTSTYLES &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This can then be define in the paragraph and character formats, which you can then be assign to texts and fields in the Smart Form. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The character formats includes effects such as superscript, subscript, barcode and font attributes. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Difference with SMARTFORMS vs. SapScript(SE71) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Following are the differences :- &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a) Multiple page formats are possible in smartforms which is not the case in SAPScripts &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;b) It is possible to have a smartform without a main window . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;c) Labels cannot be created in smartforms. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;d) Routines can be written in smartforms tool. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;e) Smartforms generates a function module when activated. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;f) Unlike sapscripts (RSTXSCRP), you cannot upload/download Smartform to your local harddisk. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It was said that it was provided in CRM 3.0 version, but not available in R/3. You can download smartforms into Local PC in a XML format. In the same way you can upload this XML format into Smartform. From the smartform editor itself you can call download option, if you are working in CRM 3.0 environment. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In R3 also, you can download into XML format. However, it's not sure about uploading. Refer to the program 'SF_XSF_DEMO'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In 4.7 Enterprise, other have seen this utlity which is completey missing in 4.6c. There is functionality to downlaod a complete form or only a particular node. (Utilities -&amp;gt; Download form). It will create a XML file and save it in the hard disk. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For others, if you want to download/upload the Smartforms source, you will need the help from the Basis people. What you can do is to create a Transport and then FTP down to your local harddisk. When you need the Smartform source in another system, you have FTP up the Smartforms file back to the SAP server. Finally, the Basis team, will tp it into your system. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;g) The protect and endprotect command in sapscript doesn't work with smartforms. For example on a invoice: First data of position no 80. is printed on page one, other data of position no 80 is printed on page 2. And there's nothing you can do about it. Actually, there is something you can do about it. By using a folder node and checking the 'protect' checkbox, everything in that folder will be page protected. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FAQ on Migrating SAPscript to SmartForms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to migrate a SAPscript form to a Smart Form? &lt;/P&gt;&lt;P&gt;Smart Forms provides a migration tool for this purpose which migrates layout and texts of a SAPscript form to a Smart Form. It does not migrate SAPscript form logic of the print program. Using Smart Forms, this logic is described by the tree structure of the Form Builder. The effort involved in migrating it depends on the complexity of the print program. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Which Basis Release do I need to use SAP Smart Forms? &lt;/P&gt;&lt;P&gt;SAP Smart Forms is available as of R/3 Basis Release 4.6C. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have heard that Smart Forms replaces SAPscript. What does "replace" mean? &lt;/P&gt;&lt;P&gt;It does not mean that SAPscript is removed from the Basis shipment. Even as of Basis Release 4.6C, SAPscript remains part of the SAP standard and there are no plans to remove it. Since Smart Forms is currently, and will continue to be, the tool for form maintenance for mySAP.com solutions, our further development efforts will focus on Smart Forms, not on SAPscript. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do we have to migrate all SAPscript forms to Smart Forms? &lt;/P&gt;&lt;P&gt;There is no point in migrating all SAPscript forms already in use. Since SAPscript can still be used and will be available in the future, there is no need to. If you plan to migrate a SAPscript form, it is recommended that you check whether benefit is worth the effort involved. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Conversion of SAPSCRIPT to SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP provides a conversion for SAPscript documents to SMARTforms. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is basically a function module, called FB_MIGRATE_FORM. You can start this function module by hand (via SE37), or create a small ABAP which migrates all SAPscript forms automatically. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also do this one-by-one in transaction SMARTFORMS, under &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Utilities -&amp;gt; Migrate SAPscript form. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You could also write a small batch program calling transaction SMARTFORMS and running the migration tool. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SmartForms System Fields &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Within a form you can use the field string SFSY with its system fields. During form processing the system replaces these fields with the corresponding values. The field values come from the SAP System or are results of the processing. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;System fields of Smart Forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-DATE&amp;amp; &lt;/P&gt;&lt;P&gt;Displays the date. You determine the display format in the user master record. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-TIME&amp;amp; &lt;/P&gt;&lt;P&gt;Displays the time of day in the form HH:MM:SS. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGE&amp;amp; &lt;/P&gt;&lt;P&gt;Inserts the number of the current print page into the text. You determine the format of the page number (for example, Arabic, numeric) in the page node. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-FORMPAGES&amp;amp; &lt;/P&gt;&lt;P&gt;Displays the total number of pages for the currently processed form. This allows you to include texts such as'Page x of y' into your output. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-JOBPAGES&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the total page number of all forms in the currently processed print request. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-WINDOWNAME&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the name of the current window (string in the Window field) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGENAME&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the name of the current page (string in the Page field) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGEBREAK&amp;amp; &lt;/P&gt;&lt;P&gt;Is set to 'X' after a page break (either automatic Page 7 or command-controlled Page 46) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-MAINEND&amp;amp; &lt;/P&gt;&lt;P&gt;Is set as soon as processing of the main window on the current page ends &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-EXCEPTION&amp;amp; &lt;/P&gt;&lt;P&gt;Contains the name of the raised exception. You must trigger your own exceptions, which you defined in the form interface, using the user_exception macro (syntax: user_exception &amp;lt;exception name &amp;gt;). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example Forms Available in Standard SAP R/3 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SF_EXAMPLE_01 &lt;/P&gt;&lt;P&gt;Simple example; invoice with table output of flight booking for one customer &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SF_EXAMPLE_02 &lt;/P&gt;&lt;P&gt;Similar to SF_EXAMPLE_01 but with subtotals &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SF_EXAMPLE_03 &lt;/P&gt;&lt;P&gt;Similar to SF_EXAMPLE_02, whereby several customers are selected in the application program; the form is called for each customer and all form outputs are included in an output request &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Smart forms Frequently Asked Questions &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Forcing a page break within table loop &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Create a loop around the table. Put a Command node before the table in the loop that forces a NEWPAGE on whatever condition you want. Then only loop through a subset of the internal table (based on the conditions in the Command node) of the elements in the Table node. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Font style and Font size &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Goto Transaction SMARTSTYLES. &lt;/P&gt;&lt;P&gt;There you can create Paragraph formats etc just like in sapscript. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then in your window under OUTPUT OPTIONS you include this SMARTSTYLE and use the Paragraph and character formats. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Line in Smartform &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Either you can use a window that takes up the width of your page and only has a height of 1 mm. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then you put a frame around it (in window output options). &lt;/P&gt;&lt;P&gt;Thus you have drawn a box but it looks like a line. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or you can just draw "__" accross the page and play with the fonts so that it joins each UNDER_SCORE. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Difference between 'forminterface' and 'global definitions' in global settings of smart forms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The Difference is as follows. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To put it very simply: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Form Interface is where you declare what must be passed in and out of the smartform (in from the print program to the smartform and out from the smartform to the print program). &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Global defs. is where you declare data to be used within the smartform on a global scope. &lt;/P&gt;&lt;P&gt;ie: anything you declare here can be used in any other node in the form. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Smartforms function module name &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once you have activated the smartform, go to the environment -&amp;gt; function module name. There you can get the name of funtion module name. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The key thing is the program that calls it. for instance, the invoice SMARTFORM LB_BIL_INVOICE is ran by the program RLB_INVOICE. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This program uses another FM to determine the name of the FM to use itself. The key thing is that when it calls this FM (using a variable to store the actual name), that the parameters match the paramters in your smartform. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another thing to note is that the FM name will change wherever the SF is transported to. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So you need to use the FM to determine the name of the SF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the code that can be use to determine the internal name of the function module: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Code: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sf_label(1) '/'. " need to resolve by name &lt;/P&gt;&lt;P&gt;move sf_label to externalname. &lt;/P&gt;&lt;P&gt;call function 'SSF_FUNCTION_MODULE_NAME' &lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;formname = externalname &lt;/P&gt;&lt;P&gt;importing &lt;/P&gt;&lt;P&gt;fm_name = internalname &lt;/P&gt;&lt;P&gt;exceptions &lt;/P&gt;&lt;P&gt;no_form = 1 &lt;/P&gt;&lt;P&gt;no_function_module = 2 &lt;/P&gt;&lt;P&gt;others = 3. &lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;message 'e427'. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;move internalname to sf_label. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It checks to see if the sf_label starts with a '/', which is how the internal names start. if it does, the name has already been converted. If not, it calls the FM and converts the name&lt;/P&gt;&lt;P&gt;one more example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Create a new smartforms &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Transaction code SMARTFORMS &lt;/P&gt;&lt;P&gt;Create new smartforms call ZSMART&lt;/P&gt;&lt;P&gt;2. Define looping process for internal table &lt;/P&gt;&lt;P&gt;Pages and windows &lt;/P&gt;&lt;P&gt;First Page -&amp;gt; Header Window (Cursor at First Page then click Edit -&amp;gt; Node -&amp;gt; Create) &lt;/P&gt;&lt;P&gt;Here, you can specify your title and page numbering &lt;/P&gt;&lt;P&gt;&amp;amp;SFSY-PAGE&amp;amp; (Page 1) of &amp;amp;SFSY-FORMPAGES(Z4.0)&amp;amp; (Total Page) &lt;/P&gt;&lt;P&gt;Main windows -&amp;gt; TABLE -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;In the Loop section, tick Internal table and fill in &lt;/P&gt;&lt;P&gt;ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2 &lt;/P&gt;&lt;P&gt;3. Define table in smartforms &lt;/P&gt;&lt;P&gt;Global settings : &lt;/P&gt;&lt;P&gt;Form interface &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB1 TYPE Table Structure &lt;/P&gt;&lt;P&gt;Global definitions &lt;/P&gt;&lt;P&gt;Variable name Type assignment Reference type &lt;/P&gt;&lt;P&gt;ITAB2 TYPE Table Structure &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. To display the data in the form &lt;/P&gt;&lt;P&gt;Make used of the Table Painter and declare the Line Type in Tabstrips Table &lt;/P&gt;&lt;P&gt;e.g. HD_GEN for printing header details, &lt;/P&gt;&lt;P&gt;IT_GEN for printing data details. &lt;/P&gt;&lt;P&gt;You have to specify the Line Type in your Text elements in the Tabstrips Output options. &lt;/P&gt;&lt;P&gt;Tick the New Line and specify the Line Type for outputting the data. &lt;/P&gt;&lt;P&gt;Declare your output fields in Text elements &lt;/P&gt;&lt;P&gt;Tabstrips - Output Options &lt;/P&gt;&lt;P&gt;For different fonts use this Style : IDWTCERTSTYLE &lt;/P&gt;&lt;P&gt;For Quantity or Amout you can used this variable &amp;amp;GS_ITAB-AMOUNT(12.2)&amp;amp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;5. Calling SMARTFORMS from your ABAP program &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT ZSMARTFORM. &lt;/P&gt;&lt;P&gt;Calling SMARTFORMS from your ABAP program. &lt;/P&gt;&lt;P&gt;Collecting all the table data in your program, and pass once to SMARTFORMS &lt;/P&gt;&lt;P&gt;SMARTFORMS &lt;/P&gt;&lt;P&gt;Declare your table type in :- &lt;/P&gt;&lt;P&gt;Global Settings -&amp;gt; Form Interface &lt;/P&gt;&lt;P&gt;Global Definintions -&amp;gt; Global Data &lt;/P&gt;&lt;P&gt;Main Window -&amp;gt; Table -&amp;gt; DATA &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming &lt;/P&gt;&lt;P&gt;&lt;A href="http://sapr3.tripod.com" target="test_blank"&gt;http://sapr3.tripod.com&lt;/A&gt; &lt;/P&gt;&lt;P&gt;TABLES: MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: FM_NAME TYPE RS38L_FNAM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF INT_MKPF OCCURS 0. &lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE MKPF. &lt;/P&gt;&lt;P&gt;DATA: END OF INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR. &lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING MKPF TO INT_MKPF. &lt;/P&gt;&lt;P&gt;APPEND INT_MKPF. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDSELECT. &lt;/P&gt;&lt;P&gt;At the end of your program. &lt;/P&gt;&lt;P&gt;Passing data to SMARTFORMS &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function 'SSF_FUNCTION_MODULE_NAME' &lt;/P&gt;&lt;P&gt;exporting &lt;/P&gt;&lt;P&gt;formname = 'ZSMARTFORM' &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;VARIANT = ' ' &lt;/P&gt;&lt;P&gt;DIRECT_CALL = ' ' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;FM_NAME = FM_NAME &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;NO_FORM = 1 &lt;/P&gt;&lt;P&gt;NO_FUNCTION_MODULE = 2 &lt;/P&gt;&lt;P&gt;OTHERS = 3. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;WRITE: / 'ERROR 1'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;call function FM_NAME &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EXPORTING &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX = &lt;/P&gt;&lt;P&gt;ARCHIVE_INDEX_TAB = &lt;/P&gt;&lt;P&gt;ARCHIVE_PARAMETERS = &lt;/P&gt;&lt;P&gt;CONTROL_PARAMETERS = &lt;/P&gt;&lt;P&gt;MAIL_APPL_OBJ = &lt;/P&gt;&lt;P&gt;MAIL_RECIPIENT = &lt;/P&gt;&lt;P&gt;MAIL_SENDER = &lt;/P&gt;&lt;P&gt;OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;USER_SETTINGS = 'X' &lt;/P&gt;&lt;P&gt;IMPORTING &lt;/P&gt;&lt;P&gt;DOCUMENT_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_INFO = &lt;/P&gt;&lt;P&gt;JOB_OUTPUT_OPTIONS = &lt;/P&gt;&lt;P&gt;TABLES &lt;/P&gt;&lt;P&gt;GS_MKPF = INT_MKPF &lt;/P&gt;&lt;P&gt;EXCEPTIONS &lt;/P&gt;&lt;P&gt;FORMATTING_ERROR = 1 &lt;/P&gt;&lt;P&gt;INTERNAL_ERROR = 2 &lt;/P&gt;&lt;P&gt;SEND_ERROR = 3 &lt;/P&gt;&lt;P&gt;USER_CANCELED = 4 &lt;/P&gt;&lt;P&gt;OTHERS = 5. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if sy-subrc 0. &lt;/P&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO &lt;/P&gt;&lt;P&gt;WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. &lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;also check &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check these links.In this,I am explaining everything step-by-step.Kindly reward points by clikcing the star on the left of reply,if it is useful.&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/ccab6730-0501-0010-ee84-de050a6cc287" target="test_blank"&gt;https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/ccab6730-0501-0010-ee84-de050a6cc287&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/8fd773b3-0301-0010-eabe-82149bcc292e" target="test_blank"&gt;https://sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/8fd773b3-0301-0010-eabe-82149bcc292e&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/3c5d9ae3-0501-0010-0090-bdfb2d458985" target="test_blank"&gt;https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/uuid/3c5d9ae3-0501-0010-0090-bdfb2d458985&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check these links also.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-basis-abap.com/sapsf001.htm" target="test_blank"&gt;http://www.sap-basis-abap.com/sapsf001.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-press.com/downloads/h955_preview.pdf" target="test_blank"&gt;http://www.sap-press.com/downloads/h955_preview.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.ossincorp.com/Black_Box/Black_Box_2.htm" target="test_blank"&gt;http://www.ossincorp.com/Black_Box/Black_Box_2.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-img.com/smartforms/sap-smart-forms.htm" target="test_blank"&gt;http://www.sap-img.com/smartforms/sap-smart-forms.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-img.com/smartforms/smartform-tutorial.htm" target="test_blank"&gt;http://www.sap-img.com/smartforms/smartform-tutorial.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sapgenie.com/abap/smartforms.htm" target="test_blank"&gt;http://www.sapgenie.com/abap/smartforms.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;hope this information is helpful...&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thnx&lt;/P&gt;&lt;P&gt;sravani&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;PLZ REWARD IF HELPFUL....&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Apr 2008 09:25:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/sap-smartforms/m-p/3747576#M901705</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-30T09:25:52Z</dc:date>
    </item>
  </channel>
</rss>

