cancel
Showing results for 
Search instead for 
Did you mean: 

NEED some help to learn smart forms more

Former Member
0 Kudos

hi to all

i am new learner,i am able to create windows,text's,graphic images and getting data from smartstyles.

But i want to learn more like prininting data dynamically using standard tables, or from standard tables data to invoice and how to use internal tables and work areas.

I am searching from 2 days to learn but i am unable to understand 100%,and i tried the few programs what i got in internet but i got some errors i am unable to solve those errors.

please help me

thanks in advance

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Banu,

Welcome to SCN.

SAP has given some demo forms, you can analyse them.

SF_ACTIVITY_INVOICE

SF_EXAMPLE_01

SF_EXAMPLE_02

SF_EXAMPLE_03

SF_HRRCF_INITIAL_EMAIL

SF_LB_INVOICE01

SF_LB_INVOICE_02

SF_LE_EXTENDED_PASS

SF_LE_PASS_PER

SF_LE_PASS_TRA

SF_SUBTOTALS

SF_TOTALS

SF_WEBFORM_02

SF_WEBFORM_03

SF_XSF_DEMO1

SF_XSF_DEMO_GREETINGS

Apart from these examples, you can avail help from SAP online with F1.

I believe, this helps you a lot.

Sripal

Former Member
0 Kudos

please tell me how can i open that examples

and please tell me how to retrive data to window from standard table,i want that,if you have any ppt please tell me

Former Member
0 Kudos

Hi Banu,

If you go to SMARTFORMS t-code and open any demo form, there will be implementation of kinds of nodes in that.

Suppose if loop is there, just drill down to that, you can get 'Data' tab, where in u give itab to print.

Similarly for 'Table' node too, try one by one, you will get it, coz, smartforms are very easier and have more features than Scripts.

Sripal

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi Bhanu,

To learn the basics refer to SDN wikis, Practise evary wiki.What exactly your error or where you are facing the errors.

Here is a sample wiki to know the basics of smartforms.

[Basics of smartforms|http://wiki.sdn.sap.com/wiki/x/wAY]

[Smartforms|http://wiki.sdn.sap.com/wiki/x/mAc ]

Hope this solves the issue.Let me know if any queries.

Regards,

Rajani

Former Member
0 Kudos

Hi Bhanu,

Refer wiki's in the below link

https://wiki.sdn.sap.com/wiki/display/ABAP/Smart+Forms

Regards,

Sravanthi

Former Member
0 Kudos

Hi,

Sorry may be my previous reply was confusing. Instead you can use the eLearnings available in SDN. On the top meuu bar you find the eLearning link.

Regards,

Aditya

Former Member
0 Kudos

hi

i opened the elearning,in that,i am unable to open that files.

that files are opening in .SIM extension,and i installed sap tutor player.exe also,how can i open or download to my system

Former Member
0 Kudos

Hi,

Hope this help a little more to understand.

SMART FORMS

	u201Csmart formsu201D are available from v4.6c onwards.
 	Transaction code is u2018SMART FORMSu201D.

DEMO:
 	Go with u2018smart formsu2019 and provide name is style and go with create.
 	Provide description for style.
 	Select paragraph formats and create node and provide identity for format P1.
 	Provide name and description.
 	Select font tab and provide font details.

              Font family       courier
              Font size           12
              Font style          bold

 	Select a character format, under this select u2018nodeu2019 option.
 	Provide an identity for character format. u2018C1u2019
 	Enter.
 	Provide a description for character format.
 	Now select u2018fontu2019 option.


 	Provide 
                         Font family       courier
                             Font size           12
                             Font style          bold

 	Now select u2018standard settingsu2019 option.

               Barcode   (for name field assign one predefined barcode)
                      Name u2013 BC_JAN

 	Select header data, provide 

               STANDARD PARAGRAPH  P1

 	Save and activate the style.
 	F3.
 	Now select u2018formu2019 option.
 	Provide u2018form nameu2019 which we are creating.
 	Go with u2018createu2019 option.
 	Provide a description for form (porder).
 	Under u2018global settingsu2019, under this select u2018form interfaceu2019 option.
 	Select u2018tablesu2019 option, nothing but internal table.

                   ITAB         LIKE           LFA1
                   JTAB         LIKE           EKKO
                   KTAB        LIKE           EKPO

 	Select u2018global definitionsu2019 option.
 	Provide variables for item amount and po amount.

                  ITEMAMOUNT         TYPE           P DECIMALS 2          0
                     POAMOUNT              TYPE          P DECIMALS 2           0

 	Global settings are for maintaining declarations required for smart forms.
 	Now select u2018pages and windowu2019 option.
 	Under this select u2018page1u2019.
 	Provide name and description for this page.

NOTE:
 	In case of smart forms, user can maintain only one main window under one page.

 	Select u201Cpage1u201D, under this select u2018windowu2019 option.
 	Provide a name and description for window.
 	(name u2013 logo, description u2013 logo window)
 	Select u2018page1u2019 and select u2018windowu2019 option.
 	Provide a description for date window. (name u2013 date, description u2013 date window)
 	Repeat the same navigation for vendor window, po window, barcode window and footer window.
 	Select u2018form painteru2019, here you can find main window provided by sap.
 	Adjust all 7 windows in page1.
 	Close the u2018form painteru2019.
 	Select u2018logo windowu2019, under this u2018graphicu2019 option.
 	Provide a name and description for logo. (graphic1, first graphic)
 	With u2018search helpu2019, find out one predefined logo and assigned one logo to that field.
 	For name field assign the logo name (enjoy).

                      NAME              ENJOY
                     OBJECT           GRAPHICS
                         ID                   BMAP

 	Select u2018date windowu2019 and description for elements.
 	Select u2018editoru2019 option.
 	u201Cgotou201D -> u201Ceditoru201D.
 	Provide variables required for a data field.

                       *         DATE:  &SFSY-DATE&
                                                  (SFSY is smart form system variable)
                       *         TIME:  &SFSY-TIME&
	
 	F3.
 	Select u2018vendor windowu2019, under this select a u201Cloopu201D option.
 	Provide a name and description for loop.

          Internal table      ITAB         INTO              ITAB (loop at itab into itab)

 	Select the loop1, under this select u2018elementsu2019 option.
 	Provide a name and description for elements.
 	Now select u2018editoru2019 option.
 	u2018gotou2019 -> u2018editoru2019.
 	Keep variables for vendor window.

                      *         VENDOR NO: &ITAB-LIFNR&
                        *         VENDOR NAME: &ITAB-NAME1&     
                        *         VENDOR COUNTRY: &ITAB-LAND1&

 	F3.
 	Select po window.
 	Select a u2018loopu2019 option.
 	Provide a name and description for logo.
 	Provide internal table

                               JTAB     INTO        JTAB.
 	Select which you provided under po window and select u2018elementsu2019 option.
 	Provide name and description.
 	Now select u2018editoru2019 option.
 	u2018gotou2019 -> u2018editoru2019.

                          *          PORDER NO: &JTAB-EBELN&
                   Line1 u2013 header
                   Line2 u2013 items

 	Select u2018patternu2019 option. (from first select the second option)
 	Now select u2018eventsu2019 option.
 	Under this enable u2018headeru2019 option.
 	Select u2018headeru2019 option now, under this select u2018elementsu2019 option.
 	Provide a name and description.
 	Select u2018new lineu2019 and u2018new cellu2019.

              LINE TYPE          HEADER

 	Now select u2018attributesu2019 option.
 	Under this select u2018editoru2019.
 	u201Cgotou201D -> u201Ceditoru201D.

                              *    ITEMS

 	F3.
 	Select u2018headeru2019, under this select u2018elementsu2019.
 	Provide name and description.
 	Now select output options.
 	Enable u2018new cellu2019.
 	Now select u2018attributesu2019, under this u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.
                              *              MATERIAL.
 	F3.
 	Select u2018headeru2019 -> u2018elementsu2019 -> u2018output optionsu2019 -> u2018enable new cellu2019.
 	Select u2018attributesu2019 option -> u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.

                             *              PRICE

 	Select u2018first sectionu2019, under this select u2018sectionu2019 option again.
 	Provide a name and description for 2nd section.
 	Enable u2018repeat processingu2019 option.
 	Now select a u2018datau2019 option.
 	Provide internal table       

                              KTAB        INTO         KTAB

 	Select 2nd section, under this select u2018elementsu2019.
 	Provide name and description.
 	Select u2018output optionu2019.
 	Enable u2018new lineu2019 and u2018new cellu2019.

                              LINE TYPE                 ITEMS

 	Now select attributes option, under attributes u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.

                             *     &KTAB-EBELP&

 	F3.
 	Select u2018item sectionu2019 and select elements.
 	Now select u2018outputu2019 options.
 	Enable u2018new cellu2019 option.
 	Select u2018attributesu2019, under this editor.
 	u2018gotou2019 -> u2018editoru2019.

                             *     &KTAB-MATNR&

 	Select u2018item sectionu2019 -> u2018elementsu2019.
 	Select output options, enable new cell.
 	Select attributes -> u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.

                              *     &KTAB-MENGE&
 	F3.
 	Select u2018quantityu2019, under this select u2018program linesu2019.


 	Provide input parameter and output parameter. (provide variables which you defined)

                   KTAB                        ITEMAMOUNT
                                                      POAMOUNT

             1          ITEMAMOUNT =   KTAB-NETWR
             2          PORDERAMOUNT = POAMOUNT + KTAB-NETWR

 	Now select u2018item sectionu2019, under this select u2018elementsu2019.
 	Select u2018output optionsu2019.
 	Enable u2018new cellu2019.
 	Select u2018attributesu2019 option, under attributes -> u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.

                               *        &ITEMAMOUNT&

 	F3.
 	Select u2018barcode windowu2019.
 	Under this select u2018elementsu2019 option.
 	Provide the style name which you already created.

                              STYLE          YBSTYLE

 	Now select u2018attributesu2019 -> u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.

                            *     <C1> &ITEMAMOUNT& </> (barcode)
                               *       &POAMOUNT& (to print in terms of value)

 	F3.
 	Select u2018footer windowu2019, under this select u2018elementsu2019.
 	Select u2018attributesu2019 option -> u2018editoru2019.
 	u2018gotou2019 -> u2018editoru2019.

                             *      PHONE NO.   27141281

 	F3.
 	Save and activate the form.
 	Execute the form.
 	You can find function module (this is system generated function module).
 	In smart forms system can generate function module automatically.

PRINT PROGRAM:
 	Let us create executable program.
 	Provide tables workarea.
                             TABLES: LFA1, EKKO, EKPO.
 	Provide selection statement based on parameters.

                            PARAMETERS: P_EBELN LIKE EKKO-EBELN.

 	Provide internal table based on LFA1, EKKO and EKPO.

                DATA: IT_ITAB LIKE LFA1 OCCURS 0 WITH HEADER LINE,
                             IT_JTAB LIKE EKKO OCCURS 0 WITH HEADER LINE,
                            IT_KTAB LIKE EKPO OCCURS 0 WITH HEADER LINE.

 	Provide select statement for finding po number which we entered is existing or not.

              SELECT * FROM EKKO INTO TABLE IT_JTAB WHERE EBELN =  
                P_EBELN.
               IF SY-DBCNT <> 0.

               SELECT * FROM LFA1 INTO TABLE IT_JTAB
               FOR ALL ENTRIES IN IT_JTAB WHERE
               LIFNR = IT_JTAB-LIFNR.

              SELECT * FROM EKPO INTO TABLE IT_KTAB
               FOR ALL ENTRIES IN IT_JTAB WHERE
               EBELN = IT_JTAB-EBELN.
               ENDIF.

 	Provide a function module which system generated.

              CALL FUNCTION u2018/1BDCWB/SF00000011u2019
                   TABLES
                                  ITAB = IT_ITAB
                                  JTAB = IT_JTAB
                                 KTAB = IT_KTAB.

 	Save and activate.
 	Execute.
 	Provide po number and execute.


MIGRATING FORM FROM SCRIPTS TO SMART FORMS:

 	Go with smart forms.
 	Under this provide user defined form name.
 	Now select utilities, under this select u2018migrate sap script formu2019.
 	Provide the form which you are migrating from scripts to form (form u2013 MEDRUCK)
 	Save and activate.

ADDING A LOGO IN SMART FORMS:
 	Let us create a bitmap file because we require a file for logo.
 	Work with u2018SE78u2019 (sap scripts graphics management).
 	Select u2018bitmapu2019 option.
 	Provide a name for logo i.e. identity for logo.
 	Select u2018coloru2019 option.
 	Now select u2018importu2019 option.
 	Provide logo filename.
 	Provide description.
 	Enter.
 	Save the details.
 	Select transport option.
 	Enter.
 	Go with smart forms; provide a form name which you migrated from sap scripts.
 	Select u2018editu2019 mode.
 	From this select u2018pages and windowsu2019 option.
 	Under this select u2018first pageu2019.
 	Under first page, select u2018header windowu2019.
 	Under this select u2018graphics optionu2019.
 	Provide a name and description for graphics.
 	Whatever you maintained in u2018se72u2019, mention that in name field now.
 	Save and activate the form.
 	Now execute the form.
 	Let us create executable program.
 	Provide function module which system generated.

CALL FUNCTION u201C/1BDCWB/SF00000012u201D.
         (No need of any parameter because we added only logo)

 	Save and activate.
 	Execute.

PREDEFINED ABAP REPORTS:

                                       SAP R/3
                                              !
                           2000 predefined abap reports

 	Go with u2018sap menuu2019.
 	Under this select u2018information systemsu2019 option.
 	Information systems have predefined abap reports.
 	Under this select u2018logisticsu2019 option.
 	Logistics have SD, MM and PP predefined abap reports.
 	Under u2018logisticsu2019, select u2018purchasingu2019 -> u2018vendoru2019 -> u2018purchasing valuesu2019 -> u2018description of reportsu2019.
 	Purchasing value reports can also be called as u2018vendor analysis reportu2019.
 	Select u2018purchasing values reportu2019 and click on that.
 	u201CSystemu201D -> u201Cstatusu201D. (With this navigation we can see source code of a report)
 	Never discuss you modified predefined abap reports.  

Regards,

Aditya

Former Member
0 Kudos

yes offcorse,yes i am trying ....i am able to create windows every thing .....want to retrive data from standard table to window...

and how to use internal table and work area , iam not getting ,i saw so many ppt examples and i tried but didnt get.