KEMBAR78
SAP Smart forms | PPTX

 SAP Smart Forms is used to create and maintain forms
for mass printing in SAP Systems.As output medium
SAP Smart Forms support a printer, a fax, e-mail, or the
Internet (by using the generated XML output).
 The transaction code is SMARTFORMS.
 Smartforms are client independent objects.
 Smartforms are advanced version of SAP Scripts.
 It is a GUI tool and it is user friendly.

 Smartform architecture:


 There are two main nodes in Smartforms.
 1.Global Settings Form Attribute.
Form Interface.
Global Definition.
2.Pages and Windows.
COMPONENTS OF SMARTFORMS.

 Global settings:
 It is used to provide the basic settings for the smartform.
 Form Attributes:
 It specifies the general attributes like who created,Date,time,
package,translate options, default smartstyle, Page format
(DINA4/DINA5).
 Form interface:
 It acts as a mediator between a driver program and a smart
form.
 The main functionality of form interface is, it will import the
parameters which are exported by driver program.
 The parameters can be variables, work areas, internal
tables..etc.
 Global definition:
 It will contain the variables to be used within the smart form.
 We can define variables, user defined data types, field symbols,
initialization code,Subroutine, currency/quantity fields.
 It is mainly used for declaring or defining the above variables.

 Page.
 Window.
 Graphic.
 Address.
 Text.
 Table.
 Header.
 Body.
 Footer.
 Template.
 Folder.
 Program Lines.
 Alternative.
 Command.
 Loop.
Pages and Windows

Pages and windows :
This will contain all the pages and the
windows, which are used in the smartform.
By default, a page will be created by name
%page1.
By default, a window will be created by
name 'Main' under the page1.
For each page, we need to specify the next
page.
Eg: page = %page1
Next page = %page1 or %page2

 Page : It is used to define the layout of a smartform.
 We can have different pages with different layouts.
 Window : it is used to display information or text at
a particular place on a page.
 Graphic : it is used to display logos or images on the
smartforms.
 Address : It is used to display the address of
customer or vendor or employee, organization
address , workplace address etc.
 Just provide address no, it will automatically display
the address as per the country formats.
Nodes under pages

 Text : it is used to display the information or text in a
window.
 Table : It is used to display the information in the form of
table.
 When ever we create table by default HEADER, MAIN
AREA, FOOTER will be displayed.
 The main functionality of a table is, it expands
automatically depending on the internal table data.
 We need to provide the name of the internal table for a
table.
 Template : template is also like a table which does not
expand. That means it will have fixed number of rows
and columns.
 Program lines : it is used to write some lines of abap
code.
Nodes under the window

 Main window: For continuous output .
 Secondary window: For output with a fixed length.
 Final window: Special type of secondary window for
outputting the information that is not known until
the end of form processing .
 Copies window: Special type of secondary window
for marking pages as copy or original.
Window Types in Smartforms

 Steps :
 Transaction : SMARTFORMS .
 Enter the Form name and click on create.

 Enter the description.

 Click on Form Painter.

 Click on Page and rename.

 To Create windows.
 Right click on page -> create -> window.


 To define Paragraph and Character formats.
 Click on Style and enter the name and click on
create.

 Paragraph formats.
 Right Click on paragraph formats -> create node->
enter name.



 Character Format :
 Right click character format -> create node



 Bar code character format .

 Click on HEADER DATA.
 Enter default paragraph (standard).
 Save , check and activate.

 Forms: To style in form.
 Go to form attributes .
 Enter the style name.

 Right click on Heading Window-> Create -> Text.

 Click on text.
 And go to general attributes.

 Enter the heading and select paragraph format.

 Upload logo image using SE78.

 Click on Logo Window.


 Whenever we are activate the SMARTDORMS,
SAP generates a Function module.

 Click on execute.


 SE38.


 Save , check and activate and execute.
 Copy the function module name.

 In SE 38.
perform call_smartform.
Call the function module name.



 Enter ADRNR in address number , paragraph format
and number of lines to be used and click on save.

 Active the program and execute.

 To Get Payer adress.


 Right click on ADD2 ->create ->address.



 Details Window :




 Column Heading.

 Click on DETAILS icon.

 Mention height and width of column.

 Right click on template -> create -> text.


 Mention the Line and column position for each text.


 To get item details.


 Right click on MAIN -> create -> Table.










 Click on Editor.


 Right click on 2nd cell ->create ->Text.













 To get Remit to address.










 Condition Window :



 To Transfer condition text : SO10.
 Go to transaction SE38.
 Run the program RSTXTRANS.


 Select Text.
 And click on trnsfr texts to corr.

 Click on yes and enter the transport request.

 Getting Text objects from standard Transaction code
into Smartforms.
 Ex : Billing documents Header text.
 VF03.


 Click on Header.

 Click on detail Icon.

 Goto->Header.


 Goto Smartforms.
 Declare a global Variable for vbeln. (G_VBELN).



 To Trigger Smart forms in Transaction.
 Go to Transaction ‘NACE’.
 Select Billing and click on output types.



 Click on processing routines.

 Copy SAP Standard program
 SE38
 Paste program name and click on display.


 Comment the existing code inside form.

 Copy data declaration from your program and paste
it in z drivr prog


 Copy all form and endform code and save it in end
new z drv prog.





 Go to Transaction NACE.
 Click on edit .
 Enter z driver program name and smartform name.

 Goto VF03 and click on print.

SAP Smart forms

  • 2.
      SAP SmartForms is used to create and maintain forms for mass printing in SAP Systems.As output medium SAP Smart Forms support a printer, a fax, e-mail, or the Internet (by using the generated XML output).  The transaction code is SMARTFORMS.  Smartforms are client independent objects.  Smartforms are advanced version of SAP Scripts.  It is a GUI tool and it is user friendly.
  • 3.
  • 4.
  • 5.
      There aretwo main nodes in Smartforms.  1.Global Settings Form Attribute. Form Interface. Global Definition. 2.Pages and Windows. COMPONENTS OF SMARTFORMS.
  • 6.
      Global settings: It is used to provide the basic settings for the smartform.  Form Attributes:  It specifies the general attributes like who created,Date,time, package,translate options, default smartstyle, Page format (DINA4/DINA5).  Form interface:  It acts as a mediator between a driver program and a smart form.  The main functionality of form interface is, it will import the parameters which are exported by driver program.  The parameters can be variables, work areas, internal tables..etc.  Global definition:  It will contain the variables to be used within the smart form.  We can define variables, user defined data types, field symbols, initialization code,Subroutine, currency/quantity fields.  It is mainly used for declaring or defining the above variables.
  • 7.
      Page.  Window. Graphic.  Address.  Text.  Table.  Header.  Body.  Footer.  Template.  Folder.  Program Lines.  Alternative.  Command.  Loop. Pages and Windows
  • 8.
     Pages and windows: This will contain all the pages and the windows, which are used in the smartform. By default, a page will be created by name %page1. By default, a window will be created by name 'Main' under the page1. For each page, we need to specify the next page. Eg: page = %page1 Next page = %page1 or %page2
  • 9.
      Page :It is used to define the layout of a smartform.  We can have different pages with different layouts.  Window : it is used to display information or text at a particular place on a page.  Graphic : it is used to display logos or images on the smartforms.  Address : It is used to display the address of customer or vendor or employee, organization address , workplace address etc.  Just provide address no, it will automatically display the address as per the country formats. Nodes under pages
  • 10.
      Text :it is used to display the information or text in a window.  Table : It is used to display the information in the form of table.  When ever we create table by default HEADER, MAIN AREA, FOOTER will be displayed.  The main functionality of a table is, it expands automatically depending on the internal table data.  We need to provide the name of the internal table for a table.  Template : template is also like a table which does not expand. That means it will have fixed number of rows and columns.  Program lines : it is used to write some lines of abap code. Nodes under the window
  • 11.
      Main window:For continuous output .  Secondary window: For output with a fixed length.  Final window: Special type of secondary window for outputting the information that is not known until the end of form processing .  Copies window: Special type of secondary window for marking pages as copy or original. Window Types in Smartforms
  • 12.
      Steps : Transaction : SMARTFORMS .  Enter the Form name and click on create.
  • 13.
      Enter thedescription.
  • 14.
      Click onForm Painter.
  • 15.
      Click onPage and rename.
  • 16.
      To Createwindows.  Right click on page -> create -> window.
  • 17.
  • 18.
      To defineParagraph and Character formats.  Click on Style and enter the name and click on create.
  • 19.
      Paragraph formats. Right Click on paragraph formats -> create node-> enter name.
  • 20.
  • 21.
  • 22.
      Character Format:  Right click character format -> create node
  • 23.
  • 24.
  • 25.
      Bar codecharacter format .
  • 26.
      Click onHEADER DATA.  Enter default paragraph (standard).  Save , check and activate.
  • 27.
      Forms: Tostyle in form.  Go to form attributes .  Enter the style name.
  • 28.
      Right clickon Heading Window-> Create -> Text.
  • 29.
      Click ontext.  And go to general attributes.
  • 30.
      Enter theheading and select paragraph format.
  • 31.
      Upload logoimage using SE78.
  • 32.
      Click onLogo Window.
  • 33.
  • 34.
      Whenever weare activate the SMARTDORMS, SAP generates a Function module.
  • 35.
  • 36.
  • 37.
  • 38.
  • 39.
      Save ,check and activate and execute.  Copy the function module name.
  • 40.
      In SE38. perform call_smartform. Call the function module name.
  • 41.
  • 42.
  • 43.
      Enter ADRNRin address number , paragraph format and number of lines to be used and click on save.
  • 44.
      Active theprogram and execute.
  • 45.
      To GetPayer adress.
  • 46.
  • 47.
      Right clickon ADD2 ->create ->address.
  • 48.
  • 49.
  • 50.
  • 51.
  • 52.
  • 53.
  • 54.
  • 55.
      Click onDETAILS icon.
  • 56.
      Mention heightand width of column.
  • 57.
      Right clickon template -> create -> text.
  • 58.
  • 59.
      Mention theLine and column position for each text.
  • 60.
  • 61.
      To getitem details.
  • 62.
  • 63.
      Right clickon MAIN -> create -> Table.
  • 64.
  • 65.
  • 66.
  • 67.
  • 68.
  • 69.
  • 70.
  • 71.
  • 72.
  • 73.
  • 74.
  • 75.
      Right clickon 2nd cell ->create ->Text.
  • 76.
  • 77.
  • 78.
  • 79.
  • 80.
  • 81.
  • 82.
  • 83.
  • 84.
  • 85.
  • 86.
  • 87.
  • 88.
      To getRemit to address.
  • 89.
  • 90.
  • 91.
  • 92.
  • 93.
  • 94.
  • 95.
  • 96.
  • 97.
  • 98.
  • 99.
  • 100.
  • 101.
      To Transfercondition text : SO10.  Go to transaction SE38.  Run the program RSTXTRANS.
  • 102.
  • 103.
      Select Text. And click on trnsfr texts to corr.
  • 104.
      Click onyes and enter the transport request.
  • 105.
      Getting Textobjects from standard Transaction code into Smartforms.  Ex : Billing documents Header text.  VF03.
  • 106.
  • 107.
  • 108.
      Click ondetail Icon.
  • 109.
  • 110.
  • 111.
      Goto Smartforms. Declare a global Variable for vbeln. (G_VBELN).
  • 112.
  • 113.
  • 114.
      To TriggerSmart forms in Transaction.  Go to Transaction ‘NACE’.  Select Billing and click on output types.
  • 115.
  • 116.
  • 117.
      Click onprocessing routines.
  • 118.
      Copy SAPStandard program  SE38  Paste program name and click on display.
  • 119.
  • 120.
      Comment theexisting code inside form.
  • 121.
      Copy datadeclaration from your program and paste it in z drivr prog
  • 122.
  • 123.
      Copy allform and endform code and save it in end new z drv prog.
  • 124.
  • 125.
  • 126.
  • 127.
  • 128.
      Go toTransaction NACE.  Click on edit .  Enter z driver program name and smartform name.
  • 129.
      Goto VF03and click on print.