RMA FORM USING SMARTFORMS

I have been requested to make a Return Material Authorization RMA form using smartforms.
My questions are: Is there any standard template/format in SAP I can use. And if there is, is there any standard ABAP program which i can use with the form (if one is required) and what are the steps to take to do and complete this task.
N.B i hava a Functional Spec docu for this and i'm also expected to write a Tech Design Docu. for it.
I'll be grateful for your help

Hi,
I think there are some examples you can use, but smartforms is quite easy to learn. I think that the SF "/SAPDII/RETPA_LIST" might be sort of what you are looking for, but if you find it to dificult, just start a new one. The SAP Help is pretty easy to follow.
As for the program to "call" the form, you will have to develop yourself, but unlike SAPSCRIPT you won't need to control the drawing of the form. In smartforms, the form generates a Function Module with an Interface, which will control the drawing of the form. The program only needs to get the info necessary and then call the FM generated with the parameters you defined in the form.
You will need only to know one FM to call the form within the report.
FM SSF_FUNCTION_MODULE_NAME - This one will return the name of the FM that was generated by the form. Parameter is the name of the smartform and return is the name of the FM.
Then you just call the FM that was returned in the previous FM (usually names are something like "/1BCDWB/SF00000006").
Reward points if found helpful....
Cheers,
Chandra Sekhar.

Similar Messages

  • Using Smartforms with Dunning

    Hi,
    I want to use a smartform (e.g. the default F150_DUNN_SF) but can't get it to work. I know the procedure:
    - go to Customizing - Financial Accounting Global Settings - Tools - Customer Enhancements - Business Transaction Events -> Settings | P/S modules | ...of an SAP appl.
    - change the FM for 1720 from FI_PRINT_DUNNING_NOTICE to FI_PRINT_DUNNING_NOTICE_SMARTF
    - go to Customizing - Financial Accounting (New) - Accounts Receivable and Payable - Business Transactions - Dunning - Printout - Assign Dunning forms
    - select a procedure and double click "Forms for normal dunning procedure" and enter a company code. Then I get the names of the forms used for each level and should be able to change them.
    There is the problem: when I fill in a smartform, like the default F150_DUNN_SF, I get the error "Form F150_DUNN_SF is not defined or is not active" (while clearly it is both). I'm guessing he only looks for sapscript forms.
    So how do I specify which smartform to use for Dunning? Has anyone managed to do this? I've read all the help and forum posts about this, saw some other people with the same problem, but no solution posted.

    I actually knew that I was supposed to ignore the error, but I couldn't get it to save. But your reply made me try clicking the green checkmark and that was the key to saving. So thank you, problem solved

  • Printing dunning notices using SMARTFORMS,error during parameter transfer

    Hi Friends,
                    I face a error message "Include text ZGA_DUN_HDR does not exist (object TEXT, ID ST)" when i run the dunning run.
                    I had searched every node for text ZGA_DUN_HDR in the smartform,I didnt find the text in it.
    However when I execute the smart form for print preview an error message "Printing dunning notices using SMARTFORMS,error during parameter transfer".This error i believe is due to wrong parameter passing in the fm 'GET_SF_DUNN_DATA'.It raises an error no_parameters_found.All parameters are passed correctly.
                    Can you guys help me out.
    Edited by: RAJIV KAUSHAL on Nov 14, 2008 6:03 PM

    you can create this text ZGA_DUN_HDR  in SO10 tcode and try ...

  • Printing Dunning Letters using Smartforms

    Hi all,
    I have a requirement wherein I need to print dunning letters using smartforms; the dunning data are extracted in program SAPF150D2;I modified the subroutine OFI_DUN_ACT to call function module FI_PRINT_DUNNING_NOTICE_SMARTF.
    Now I need to extract the dunning data in program SAPF150D2 to be imported to my new form using GET_SF_DUNN_DATA, my question is where do I code the calling of FM GET_SFG_DUNN_DATA? I'm a little bit confused on the step by step process of the dunning data extraction to printing of the form... Thanks...

    In the INITIALIZATION of the Smartforms, after the call to  GET_SF_DUNN_DATA, you have a many informations back, of which the record of MHNK and an internal table of MHND, which you can use to select other informations from database.
    So fill or enrich your own internal table in the initialization.
    I enclose thereafter a sample to help you
    * Load data
      CALL FUNCTION 'GET_SF_DUNN_DATA'
           EXPORTING
                is_sfparam          = is_sfparam
           IMPORTING
                es_mhnk             = mhnk
                es_t001             = t001
                es_knb5             = knb5
                es_lfb5             = lfb5
                es_t047             = t047
                es_t047c            = t047c
                es_t047i            = t047i
                es_t056z            = t056z
                es_f150d            = f150d
                es_fsabe            = fsabe
                es_adrnr            = adrnr
                es_uadrnr           = uadrnr
                es_adrs             = adrs
                es_uadrs            = uadrs
                es_t047b            = t047b
                eb_testprint        = testprint
                e_langu             = langu
                e_lang2             = lang2
                es_f150d_esr        = f150d_esr
                es_paymi            = paymi
                es_paymo            = paymo
           TABLES
                t_mhnd              = th_mhnd
           EXCEPTIONS
                no_parameters_found = 1
                OTHERS              = 2.
    IF sy-subrc <> 0.
      sy-msgid = 'FM'.
      sy-msgty = 'E'.
      sy-msgno = 461.
      RAISE others.
    ENDIF.
    h_t040a-text1 = space.
    show_interest = space.
    LOOP AT th_mhnd INTO mhnd WHERE xzins = ' '.
      show_interest = 'X'.
      EXIT.
    ENDLOOP.
    * Load user information
    DATA: usr21 LIKE usr21, addr3_sel LIKE addr3_sel.
    CLEAR: usr21, addr3_sel, addr3_val, adr6.
    * Charger fiche profil
    SELECT SINGLE * FROM usr21 WHERE bname = sy-uname.
    * Récupérer l'adresse
    MOVE-CORRESPONDING usr21 TO addr3_sel.
    CALL FUNCTION 'ADDR_PERS_COMP_GET'
         EXPORTING
              address_pers_in_comp_selection = addr3_sel
         IMPORTING
              address_pers_in_comp_value     = addr3_val
         EXCEPTIONS
              OTHERS                         = 1.
    * load SMTP address
    CLEAR adr6.
    SELECT SINGLE * FROM adr6
      WHERE addrnumber = usr21-addrnumber
        AND persnumber = usr21-persnumber.
    * date format
    SET COUNTRY adrs-land1.
    * Group similar posts
    DATA: xbseg TYPE bseg,
          xbkpf TYPE bkpf,
          xpost TYPE th_outtab.
    REFRESH: t_post, t_cumul_waers.
    LOOP AT th_mhnd INTO mhnd.
    * Select lines to use
      IF mhnk-gmvdt IS INITIAL.
        IF mhnd-xzalb <> space OR mhnd-mansp <> space.
          CONTINUE.
        ELSEIF t047b-xpost NE 'X' AND mhnd-xfael <> 'X'.
          CONTINUE.
        ENDIF.
      ENDIF.
    * Map data
      CLEAR xpost.
      MOVE-CORRESPONDING mhnd TO xpost.
    * Load text from bseg
      SELECT SINGLE sgtxt INTO xpost-sgtxt FROM bseg
        WHERE bukrs EQ mhnd-bbukrs AND belnr EQ mhnd-belnr
          AND gjahr EQ mhnd-gjahr  AND buzei EQ mhnd-buzei.
      PERFORM edit_text CHANGING xpost-zuonr mhnd-xblnr xpost-sgtxt.
    * if "Payment difference" get the date of original document
      IF mhnd-bschl = '06'.
        SELECT SINGLE bldat INTO xpost-bldat
          FROM bkpf
          WHERE bukrs = mhnd-bukrs
            AND belnr = mhnd-rebzg
            AND gjahr = mhnd-rebzj.
      ENDIF.
    * Collect posts to print
      COLLECT xpost INTO t_post.
    * Collect amount per currency
      MOVE-CORRESPONDING xpost TO cumul.
      COLLECT cumul INTO t_cumul_waers.
    ENDLOOP.
    * Load customer information
    SELECT SINGLE * FROM kna1 INTO kna1
      WHERE kunnr = mhnk-kunnr.
    SELECT SINGLE * FROM knb1 INTO knb1
      WHERE bukrs = mhnk-bukrs
        AND kunnr = mhnk-kunnr.
    * Convert date to text
    PERFORM convert_date USING control_parameters-langu mhnk-laufd
      CHANGING text_date.
    PERFORM convert_date USING control_parameters-langu mhnk-prndt_before
      CHANGING text_prev.
    PERFORM convert_date USING control_parameters-langu mhnk-grdat
      CHANGING text_extr.
    Regards

  • How to Print form using SAP Smart Forms which is migrated from SAP Script?

    Hello every one,
         i have a problem in printing form using smart form which is migrate from the SAP Script...so what method i have to use...if any one know the solution for this than plz reply me as soon as possible...

    hi
    when ever u want to migrate the script to smartform u have to chage the driver program also..
    refere this link to convert script to smartform
    convert sapscript to smartform
    c_formname = u r smartform name...
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
      EXPORTING
        formname           = c_formname
      IMPORTING
        fm_name            = v_fm_name
      EXCEPTIONS
        no_form            = 1
        no_function_module = 2
        OTHERS             = 3.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    ...........................CALL SMARTFORM............................
    CALL FUNCTION v_fm_name
      EXPORTING
        control_parameters   = st_control_parameters
        output_options       = st_output_options
      IMPORTING
        document_output_info = st_document_output_info
        job_output_info      = st_job_output_info
        job_output_options   = st_job_output_options
      EXCEPTIONS
        formatting_error     = 1
        internal_error       = 2
        send_error           = 3
        user_canceled        = 4
        OTHERS               = 5.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.

  • PDF Properties: How to Set Using Smartforms

    Hi.
    Is it possible to Set the properties of PDF forms from SMARTFORMS? When you open PDF, File --> Properties --> Security --> Filling of Fields: Not Allowed. How do i set it to Not Allowed? Is this something that can be handled by SMARTFORMS? We are using CL_DOCUMENT_BCS to send the pdf as attachment.
    Thanks,
    Louisse

    hi,
    use CONVERT_OTF_2_PDF function module for converting otf to pdf
    use SO_NEW_DOCUMENT_ATT_SEND_API1 function module for sending pdf as attachment
    you will get required output.
    regards,
    anil

  • Purchase order layout using Smartform

    Hi All,
    Can anyone let me know how to create Purchase order layout using smartforms and assigning it to output type.
    Is there standard smartform for purchase order?

    http://smoschid.tripod.com/How_to_do_things_in_SAP/How_To_Build_SMARTFORMS/How_To_Build_SMARTFORMS.html
    http://www.sap-basis-abap.com/sapsf001.htm
    http://help.sap.com/printdocu/core/Print46c/de/data/pdf/BCSRVSCRSF/BCSRVSCRSF.pdf
    http://www.sap-img.com/smartforms/smartforms-faq-part-two.htm
    http://www.esnips.com/doc/13b7ae7a-b32c-4b96-b588-881859d4ac99/Template,Table,Loop,Command-in-Smartforms.doc
    http://www.esnips.com/doc/97acb00a-e513-4611-91f0-c626f460bfc5/Smart_Form_Overview.pdf
    http://www.esnips.com/doc/77a981b9-8fe3-4fbb-8101-67745c1fe60c/SMART-FORMS_shail.ppt
    http://www.sap-basis-abap.com/sapsf001.htm
    http://www.sap-press.com/downloads/h955_preview.pdf
    http://www.ossincorp.com/Black_Box/Black_Box_2.htm
    http://www.sap-img.com/smartforms/sap-smart-forms.htm
    Try this. A simple sample Smart Form.
    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).
    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).
    1. Create a new smartforms
    Transaction code SMARTFORMS
    Create new smartforms call ZSMART
    2. Define looping process for internal table
    Pages and windows
    First Page -> Header Window (Cursor at First Page then click Edit -> Node -> Create)
    Here, you can specify your title and page numbering
    &SFSY-PAGE& (Page 1) of &SFSY-FORMPAGES(Z4.0)& (Total Page)
    Main windows -> TABLE -> DATA
    In the Loop section, tick Internal table and fill in
    ITAB1 (table in ABAP SMARTFORM calling function) INTO ITAB2
    3. Define table in smartforms
    Global settings :
    Form interface
    Variable name Type assignment Reference type
    ITAB1 TYPE Table Structure
    Global definitions
    Variable name Type assignment Reference type
    ITAB2 TYPE Table Structure
    4. To display the data in the form
    Make used of the Table Painter and declare the Line Type in Tabstrips Table
    e.g. HD_GEN for printing header details,
    IT_GEN for printing data details.
    You have to specify the Line Type in your Text elements in the Tabstrips Output options.
    Tick the New Line and specify the Line Type for outputting the data.
    Declare your output fields in Text elements
    Tabstrips - Output Options
    For different fonts use this Style : IDWTCERTSTYLE
    For Quantity or Amout you can used this variable &GS_ITAB-AMOUNT(12.2)&
    5. Calling SMARTFORMS from your ABAP program
    REPORT ZSMARTFORM.
    Calling SMARTFORMS from your ABAP program.
    Collecting all the table data in your program, and pass once to SMARTFORMS
    SMARTFORMS
    Declare your table type in :-
    Global Settings -> Form Interface
    Global Definintions -> Global Data
    Main Window -> Table -> DATA
    Written by : SAP Hints and Tips on Configuration and ABAP/4 Programming
    http://sapr3.tripod.com
    TABLES: MKPF.
    DATA: FM_NAME TYPE RS38L_FNAM.
    DATA: BEGIN OF INT_MKPF OCCURS 0.
    INCLUDE STRUCTURE MKPF.
    DATA: END OF INT_MKPF.
    SELECT-OPTIONS S_MBLNR FOR MKPF-MBLNR MEMORY ID 001.
    SELECT * FROM MKPF WHERE MBLNR IN S_MBLNR.
    MOVE-CORRESPONDING MKPF TO INT_MKPF.
    APPEND INT_MKPF.
    ENDSELECT.
    At the end of your program.
    Passing data to SMARTFORMS
    call function 'SSF_FUNCTION_MODULE_NAME'
    exporting
    formname = 'ZSMARTFORM'
    VARIANT = ' '
    DIRECT_CALL = ' '
    IMPORTING
    FM_NAME = FM_NAME
    EXCEPTIONS
    NO_FORM = 1
    NO_FUNCTION_MODULE = 2
    OTHERS = 3.
    if sy-subrc <> 0.
    WRITE: / 'ERROR 1'.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    call function FM_NAME
    EXPORTING
    ARCHIVE_INDEX =
    ARCHIVE_INDEX_TAB =
    ARCHIVE_PARAMETERS =
    CONTROL_PARAMETERS =
    MAIL_APPL_OBJ =
    MAIL_RECIPIENT =
    MAIL_SENDER =
    OUTPUT_OPTIONS =
    USER_SETTINGS = 'X'
    IMPORTING
    DOCUMENT_OUTPUT_INFO =
    JOB_OUTPUT_INFO =
    JOB_OUTPUT_OPTIONS =
    TABLES
    GS_MKPF = INT_MKPF
    EXCEPTIONS
    FORMATTING_ERROR = 1
    INTERNAL_ERROR = 2
    SEND_ERROR = 3
    USER_CANCELED = 4
    OTHERS = 5.
    if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    SMARTFORMS GENERATION: (calling internal table fields)
    &#61656; Open a smartform using the tcode ‘smartforms’.
    &#61656; Usually form attributes shows admn data.
    &#61656; In the form interface declare import/export parameters if any. Else declare the tables in tables tab button.
    &#61656; In the windows and pages expand and create a table. It automatically generates header, main area and footer for the table.
    &#61656; In data tab button in the table we usually declare a work area to bring the data from se38. Like: ktab into wa. ( The purpose of declaring the wa is , to get the data of the ktab in to header from the body area of the internal table).
    &#61656; And in the tablepainter pushbutton in table we can have any no of line types. Depending on the requirement. ( for ex: If we want to devide a row in to 4 columns, we can devide it as 4,4,4,4cm as line type 1, And usually for the footer we don’t need no of columns, So, we declare it as one column with 16cm measure with the name line type 2.). We can use these line types in the tables.
    &#61656; In the header right click>>create>>tableline. It asks for line type. Select one line type which is appropriate.
    &#61656; Like same create a row2 in main area using right click. If we select the line type 1, it automatically generates 4 cells. We can create text in each cell as per requirement.
    &#61656; We can generate general attributes using general attributes tab button in the text. Or in the other way. We can switch on the field list on/off button from the application tool bar. It displays all the attributes in the left down corner of the screen. We can drag and drop the required fields in the general attributes tab button of the text.
    &#61656; We continue the same procedure for all the texts. The texts should be displayed in the gray color. Then only it can collects the data from the abap editor fields.
    &#61656; If it wont turns gray, we can check the fields in the editor by changing it to the line editor. The best thing is to drag the fields from the list, rather than declaring like &wa-matnr&
    &#61656; In the footer also we create a line type and in that table line we create text.
    SE38 PROGRAM(method I):
    REPORT Z_CALLING_SMARTFORM2 .
    tables: mara.
    select-options: S_MATNR for MARA-MATNR.
    DATA: kTAB LIKE MARA OCCURS 1 WITH HEADER LINE.
    data: FM_NAME TYPE RS38L_FNAM.
    SELECT * FROM MARA INTO TABLE kTAB WHERE MATNR in
    S_MATNR.
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
    EXPORTING
    formname = 'Z_MYFIRST_FORM2'
    VARIANT = ' '
    DIRECT_CALL = ' '
    IMPORTING
    FM_NAME = FM_NAME
    EXCEPTIONS
    NO_FORM = 1
    NO_FUNCTION_MODULE = 2
    OTHERS = 3
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    CALL FUNCTION fm_name
    EXPORTING
    ARCHIVE_INDEX =
    ARCHIVE_INDEX_TAB =
    ARCHIVE_PARAMETERS =
    CONTROL_PARAMETERS =
    MAIL_APPL_OBJ =
    MAIL_RECIPIENT =
    MAIL_SENDER =
    OUTPUT_OPTIONS =
    USER_SETTINGS = 'X'
    IMPORTING
    DOCUMENT_OUTPUT_INFO =
    JOB_OUTPUT_INFO =
    JOB_OUTPUT_OPTIONS =
    TABLES
    ktab = ktab
    EXCEPTIONS
    FORMATTING_ERROR = 1
    INTERNAL_ERROR = 2
    SEND_ERROR = 3
    USER_CANCELED = 4
    OTHERS = 5
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    IN THE OTHER WAY(method II):
    REPORT Z_CALLING_SMARTFORM2 .
    tables: mara.
    select-options: S_MATNR for MARA-MATNR.
    DATA: kTAB LIKE MARA OCCURS 1 WITH HEADER LINE.
    SELECT * FROM MARA INTO TABLE kTAB WHERE MATNR in S_MATNR.
    CALL FUNCTION '/1BCDWB/SF00000199'
    EXPORTING
    ARCHIVE_INDEX =
    ARCHIVE_INDEX_TAB =
    ARCHIVE_PARAMETERS =
    CONTROL_PARAMETERS =
    MAIL_APPL_OBJ =
    MAIL_RECIPIENT =
    MAIL_SENDER =
    OUTPUT_OPTIONS =
    USER_SETTINGS = 'X'
    IMPORTING
    DOCUMENT_OUTPUT_INFO =
    JOB_OUTPUT_INFO =
    JOB_OUTPUT_OPTIONS =
    TABLES
    ktab = ktab
    EXCEPTIONS
    FORMATTING_ERROR = 1
    INTERNAL_ERROR = 2
    SEND_ERROR = 3
    USER_CANCELED = 4
    OTHERS = 5
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    In the method I we are calling the amartform dynamically using the function module 'SSF_FUNCTION_MODULE_NAME'.
    Here we are exporting form name and importing fm_name.
    So we need to declare the variable fm_name as
    data: FM_NAME TYPE RS38L_FNAM.
    We can have the type of the fm_name in the function module 'SSF_FUNCTION_MODULE_NAME' (in the export tab button).
    Since we are passin the name of the Function module generated by the smart form in to the fm_name variable. We run the function module with the name fm_name, but not the FM generated by the smartform(like /1BCDWB/SF00000199)¬¬¬¬¬¬.
    In the method II we directly call the smartform generated function module (i.e, /1BCDWB/SF00000199).
    But the method I is recommended. In the method I, The fm_name is a variable we don’t put it in the quotes while calling.
    In the both methods we declare the internal table using the like option, but not begin of…. end of. And in select statement we select *, But not individual fields.
    EX2:
    SMART FORM NAME: ZGITI_FORM1.
    SE38:
    REPORT Z_CALL_GIRI_FORM1 .
    TABLES: VBRK.
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE T1.
    SELECT-OPTIONS: S_VBELN FOR VBRK-VBELN.
    SELECTION-SCREEN END OF BLOCK B1.
    *INITIALIZATION.
    *T1 = 'SELECTION-CRIETERIA'.
    DATA: BEGIN OF I_INVOICE OCCURS 1.
    INCLUDE STRUCTURE ZSTR_INVOICE.
    DATA: END OF I_INVOICE.
    DATA: VAR1 LIKE VBRP-NETWR.
    DATA: BEGIN OF I_ADDRESS OCCURS 1.
    INCLUDE STRUCTURE ZSTR_ADDRESS.
    DATA: END OF I_ADDRESS.
    DATA: BEGIN OF I_ORDER OCCURS 1.
    INCLUDE STRUCTURE ZSTR_ORDER.
    DATA: END OF I_ORDER.
    DATA: BEGIN OF I_ITEM OCCURS 1.
    INCLUDE STRUCTURE ZSTR_ITEM.
    DATA: END OF I_ITEM.
    DATA: BEGIN OF I_VBFA OCCURS 1,
    VBELV LIKE VBFA-VBELV,
    VBELN LIKE VBFA-VBELN,
    END OF I_VBFA.
    SELECT KUNAG VBELN VKORG VTWEG SPART FROM VBRK INTO TABLE I_INVOICE
    WHERE VBELN IN S_VBELN.
    IF I_INVOICE[] IS NOT INITIAL.
    SELECT KUNNR LAND1 NAME1 NAME2 ORT01 PSTLZ REGIO FROM
    KNA1 INTO CORRESPONDING FIELDS OF TABLE I_ADDRESS FOR ALL ENTRIES IN
    I_INVOICE WHERE KUNNR = I_INVOICE-KUNAG.
    ENDIF.
    IF I_INVOICE[] IS NOT INITIAL.
    SELECT VBELV VBELN FROM VBFA INTO TABLE I_VBFA FOR ALL ENTRIES IN
    I_INVOICE WHERE VBELN = I_INVOICE-VBELN.
    ENDIF.
    IF I_VBFA[] IS NOT INITIAL.
    SELECT VBELN BSTNK FROM VBAK INTO CORRESPONDING FIELDS OF TABLE I_ORDER
    FOR ALL ENTRIES IN I_VBFA WHERE VBELN = I_VBFA-VBELV.
    ENDIF.
    IF I_INVOICE[] IS NOT INITIAL.
    SELECT POSNR MATNR ARKTX FKIMG NETWR FROM VBRP INTO TABLE I_ITEM FOR ALL
    ENTRIES IN I_INVOICE WHERE VBELN = I_INVOICE-VBELN.
    ENDIF.
    LOOP AT I_ITEM.
    AT LAST.
    SUM.
    VAR1 = I_ITEM-NETWR.
    ENDAT.
    ENDLOOP.
    CALL FUNCTION '/1BCDWB/SF00000223'
    EXPORTING
    ARCHIVE_INDEX =
    ARCHIVE_INDEX_TAB =
    ARCHIVE_PARAMETERS =
    CONTROL_PARAMETERS =
    MAIL_APPL_OBJ =
    MAIL_RECIPIENT =
    MAIL_SENDER =
    OUTPUT_OPTIONS =
    USER_SETTINGS = 'X'
    var = VAR1
    IMPORTING
    DOCUMENT_OUTPUT_INFO =
    JOB_OUTPUT_INFO =
    JOB_OUTPUT_OPTIONS =
    tables
    i_vbrk = I_INVOICE
    i_vbak = I_ORDER
    i_vbrp = I_ITEM
    i_kna1 = I_ADDRESS
    EXCEPTIONS
    FORMATTING_ERROR = 1
    INTERNAL_ERROR = 2
    SEND_ERROR = 3
    USER_CANCELED = 4
    OTHERS = 5
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

  • How to create a smart form using the purchase order

    hi everybody............
    i have created one purchase order, i want to print that PO using smartforms rather than scripts. how can i do it, can anyone help me out in solving the issue. i am using the version sap 4.7
    Edited by: mhyderali on Aug 21, 2009 4:08 PM

    Hi,
    Before answer your question few things i would like to kno:
    1. currently is there any script is printing while displaying output.
    2. do u allready hae a smartform or you are going to develop a smartform.
    3. if you dont have a smartform and there is a script attached then you can convert script into smartform and then you can change in the smart form accordingly.
    4. after devloping a new smart form or converting script into smartform what you need to do is go to V/83 transaction give Output Type which is associated with script and Application area (for purchase order i.e. EF). then press ok screen will display here you can change the name of your form name under the form column.
    6. if you dnt have the Output type then you need to create a output type for the purchase order.
    Please let me know if you have still some question.
    Thanks
    Narendra

  • Error "number out of range" in pdf sent through mail using smartform outpu

    Hi Experts,
    We have a program which sends mail using smartform output in 'PDF' format. We are able to preview smartform correctely in SAP and mail is also getting sent fine with attachment of form as PDF document. But, when we try to open the document, it gives error saying 'Number out of range'. Also, not all of the windows of smartform are appearing in document and some are coming only half.
    We are not able to find out the reason for this. Any help would be appriciated.

    Hi Soumya,
    Have you got the solution as we are facing the same issue.
    Cheers,
    Bharath

  • Error "number out of range" in pdf sent through mail using smartform output

    Hi Experts,
    We have a program which sends mail using smartform output in 'PDF' format. We are able to preview smartform correctely in SAP and mail is also getting sent fine with attachment of form as PDF document. But, when we try to open the document, it gives error saying 'Number out of range'. Also, not all of the windows of smartform are appearing in document and some are coming only half.
    We are not able to find out the reason for this. Any help would be appriciated.
    Gouri.

    Hello,
    How did you solve this one? We are facing the same problem in ECC6.0.
    Thanks in advance,
    Benjamin de Rijke

  • Interactive document using Smartforms

    Hi,
    The customer wants an interactive page to be developed using Smartforms with editable text field and checkboxes. Can this be done in Smartforms? If yes then can you please tell how to do it?
    I thought Smartforms in for output only. Can it be used to take inputs and perform some events based on these inputs?
    Please reply asap as the customer is behind me and I need to say if it is possible or not..
    Thanks in advance,
    Rashmi

    Rashmi,
    You will have to use the new ADOBE forms, which are interactive and the user can enter data. But I think its available with WAS 6.40. The transaction code is SFP.
    I am not sure which version of SAP / BASIS your on. If you are SAP R/3 4.6C or 4.7, this might not work.
    Hope this helps.
    Regards,
    Ravi
    Note : Please reward points if this helps.

  • Problem with interactive forms using ABAP

    Hi all,
        I am trying to create an interactive adobe form using ABAP in ECC 6.0. But while execute the form, it is creating an error saying that
    Exception       SYSTEM_ERROR
    Message ID:          FPRUNX                     Message number:           001
    Message:
    ADS: The render error log file has been written to D:\u(200101)
    But i was able to create adobe interactive form using WebDynpro and its working perfectly. But the problem is while using ABAP method.
    Do anyone have an idea why its happening?
    Thanks and Regards,
    Raja Sekhar

    Hi
    Interactive Forms based on Adobe software is SAP's new solution for forms development. Its first release has the focus on interactive use of forms. High-volume printing is supported in principle, but - being a new solution - the performance has not yet reached the same level as Smart Forms or SAPscript, two established solutions that had years to grow. Interactive Forms is the only solution that will continue to be enhanced with new features, while SAPscript and Smart Forms will be supported without limitations.
    When (or if) to move to Interactive Forms depends on your requirements. For interactive forms usage, i.e. the new functions, you have no choice, as the existing solutions don't support it. High-volume print scenarios need to be carefully analyzed to see whether your concrete requirements can be met at this point.
    However, it is possible to move to Smart Forms and design your forms in such a way that a migration at any point in the future would be but a small step. Smart Forms offers from Web AS 6.40 a migration wizard to Interactive Forms. Technically, everything can be migrated, but we recommend against things like ABAP program nodes, for example.
    You are not forced to ever go to Interactive Forms if you don't want to. It really depends on whether your client needs any of the new features in Interactive Forms. Also, if they are currently working with JetForms, they could enquire with Adobe directly what migration path they offer to the joint solution.
    It is impossible to make a blanket statement on what needs to be done in each of the applications using a form for output. Despite the same underlying technology, forms handling has always been a decision for each SAP application: Some do it through customizing, some through coding, some in yet anither way.
    What I CAN say from a technology pespective is that all applications are in the process of creating their forms based on Interactive Forms so that by 2007 pretty much all SAP forms will be PDF-based. Obviously, each application does it within the framework of their application - but they all use Interactive Forms.
    By the way, be aware that in ERP 2004 this forms solution is subject to a limitation for high-volume printing scenarios as we cannot ensure that ALL customers will be content with the performance in ALL scenarios with this release. (see SAP Note 863893).
    To get an overview idea about Adobe forms ,
    Using SFP , first you need to create a interface . in interface you can declare the import and export parameters and also the declaration part, coding etc : This is nothing but similar to Function module interface.
    And now we have to create the Form which is interactive. Create the form and enter the interface name which you have created in first step, so that the parameters , declarations of fields etc : will be copied and available in the form layout. So that you can drag and drop these declared fields ( dclared fields of interface ) to the layout.
    Create the context and layout in the form.
    The layout generated can be previewed and saved as PDF output.
    Now we need to integrate the driver program and the PDF form to get the final output as per the requirement.
    On activating and executing the form you will get a function module name just similar to smartforms.
    The driver program needs to call this FM.
    Refer to the below sample code :
    DATA : is_customer TYPE scustom.
    DATA : it_bookings TYPE ty_bookings.
    DATA : iv_image_url TYPE string.
    DATA : iv_sending_country TYPE adrc-country.
    DATA : it_sums TYPE TABLE OF flprice_t.
    DATA : docparams TYPE sfpdocparams.
    DATA : formoutput TYPE fpformoutput.
    DATA : outputparams TYPE sfpoutputparams.
    PARAMETERS : pa_cusid TYPE scustom-id.
    SELECT SINGLE * FROM scustom INTO is_customer
    WHERE id = pa_cusid.
    SELECT * FROM sbook
    INTO CORRESPONDING FIELDS OF TABLE it_bookings
    WHERE customid = pa_cusid.
    outputparams-nodialog = 'X'.
    outputparams-getpdf = 'X'.
    *outputparams-adstrlevel = '02'.
    CALL FUNCTION 'FP_JOB_OPEN'
    CHANGING
    ie_outputparams = outputparams
    EXCEPTIONS
    cancel = 1
    usage_error = 2
    system_error = 3
    internal_error = 4
    OTHERS = 5.
    IF sy-subrc <> 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
    docparams-langu = 'E'.
    docparams-country = 'US'.
    docparams-fillable = 'X'.
    CALL FUNCTION '/1BCDWB/SM00000043'
    EXPORTING
    /1bcdwb/docparams = docparams
    is_customer = is_customer
    it_bookings = it_bookings
    IV_IMAGE_URL =
    iv_sending_country = 'US'
    IT_SUMS =
    IMPORTING
    /1bcdwb/formoutput = formoutput
    EXCEPTIONS
    usage_error = 1
    system_error = 2
    internal_error = 3
    OTHERS = 4
    IF sy-subrc <> 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
    CALL FUNCTION 'FP_JOB_CLOSE'
    IMPORTING
    E_RESULT =
    EXCEPTIONS
    usage_error = 1
    system_error = 2
    internal_error = 3
    OTHERS = 4
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    http://help.sap.com/saphelp_nw04/helpdata/en/d2/4a94696de6429cada345c12098b009/frameset.htm
    https://www.sdn.sap.com/irj/sdn/interactiveforms-elearning
    /people/thomas.jung3/blog/2005/07/13/lessons-learned-from-adobe-forms-development
    /people/community.user/blog/2006/11/20/search-help-in-isr-adobe-forms
    /people/franklin.herbas/blog/2005/12/13/2d-barcode-pdf-forms-with-sap-netweaver
    /people/vani.krishnamoorthy/blog/2006/05/17/fillable-adobe-forms-using-abap
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/849b3482206353e10000000a11466f/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/82538c0c4458bbe10000000a422035/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/46/55c841d202c317e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/6d/bd2d828aa04eeb9451aad0d02ae9a0/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/dd/60694fddb74ad88cdb7d2a094f3dd2/frameset.htm
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/d4fe7fca-0b01-0010-569a-9a9c1ddf4132
    https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/7c3bc67e-0c01-0010-dbb3-908315896909 [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/7c3bc67e-0c01-0010-dbb3-908315896909 [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    /people/vani.krishnamoorthy/blog/2006/05/17/fillable-adobe-forms-using-abap
    https://www.sdn.sap.com/irj/sdn/interactiveforms
    http://www.sap.com/company/press/press.epx?pressID=2785
    http://www.adobe.com/enterprise/partners/sap.html
    http://www.adobe.com/enterprise/partners/pdfs/sap_datasheet.pdf
    look at the Adobe page here in SDN:
    https://www.sdn.sap.com/sdn/developerareas/was.sdn?page=AdobeForms.htm
    Check these links on Adobe forms
    http://help.sap.com/saphelp_nw04/helpdata/en/1e/05853ff8ec2c17e10000000a114084/content.htm
    https://www.sdn.sap.com/irj/sdn/interactiveforms
    http://www.sap.com/solutions/solutionextensions/pdf/BWP_Interactive_Forms_Adobe.pdf
    It contains lots of useful information, documentation, and e-learning materials teaching you the basics.
    http://help.sap.com/saphelp_nw2004s/helpdata/en/b7/64348655fb46149098d95bdca103d0/frameset.htm
    Use the Tcode : SFP
    https://www.sdn.sap.com/sdn/developerareas/was.sdn?page=AdobeForms.htm
    Check these links on Adobe forms
    http://help.sap.com/saphelp_nw04/helpdata/en/1e/05853ff8ec2c17e10000000a114084/content.htm
    https://www.sdn.sap.com/irj/sdn/interactiveforms
    http://www.sap.com/solutions/solutionextensions/pdf/BWP_Interactive_Forms_Adobe.pdf
    It contains lots of useful information, documentation, and e-learning materials teaching you the basics.
    http://help.sap.com/saphelp_nw2004s/helpdata/en/b7/64348655fb46149098d95bdca103d0/frameset.htm
    Very useful
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/webcontent/uuid/00f4f594-7306-2a10-8483-b45bec157093 [original link is broken]
    for PDF forms
    http://help.sap.com/saphelp_nw04/helpdata/en/c8/4adf7ba13c4ac1b4600d4df15f8b84/content.htm
    See the links for debugging
    Refer to this thread
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    Debugging
    Check these documents.
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_nw04/helpdata/en/5a/4ed93f130f9215e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_47x200/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://www.cba.nau.edu/haney-j/CIS497/Assignments/Debugging.doc
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/84/1f624f4505144199e3d570cf7a9225/frameset.htm
    http://help.sap.com/saphelp_bw30b/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    http://help.sap.com/saphelp_erp2005/helpdata/en/b3/d322540c3beb4ba53795784eebb680/frameset.htm
    ABAP Debugging
    http://www.saplinks.net/index.php?option=com_content&task=view&id=24&Itemid=34
    Look at the SAP help link below
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c6/617ca9e68c11d2b2ab080009b43351/content.htm
    For online PDF form creation...........
    https://createpdf.adobe.com/index.pl?BP=IE&LOC=en_US
    for Other information use these Links
    C:Documents and Settingsvuser01DesktopSANKET SPersonalVikalpsap netweaver ABAP and adobe Formspdf form webpdf based print forms.htm
    C:Documents and Settingsvuser01DesktopSANKET SPersonalVikalpsap netweaver ABAP and adobe Formspdf form webSAP Interactive Forms by Adobe.htm
    http://searchsap.techtarget.com/generic/0,295582,sid21_gci1079310,00.html?Offer=SAPwn927nw
    http://www.thespot4sap.com/articles/SAP_Netweaver_Introduction.asp
    http://help.sap.com/saphelp_webas630/helpdata/en/cb/f4bc3d42f46c33e10000000a11405a/content.htm
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/c7cbe08d-0c01-0010-8bac-b9ce7348246c?source=gawindev09&kw=sap+netweaver&adgroup=brand_netweaver
    https://www.sdn.sap.com/irj/sdn/downloaditem?rid=/library/uuid/cfc19866-0401-0010-35b2-dc8158247fb6
    https://websmp204.sap-ag.de/~sapidp/011000358700004952682004E
    /people/venkata.ramisetti/blog/2006/09/21/configuring-output-types-for-pdf-based-print-forms
    http://help.sap.com/saphelp_erp2005vp/helpdata/en/96/6ee0d5b39640d68fc0078fc575114a/frameset.htm
    D:adobe livecycle designerAdobe_Designer_71BeforeInstall.htm
    http://sdn.sap.com/irj/sdn/interactiveforms
    very imp ADS configuration guide
    http://help.sap.com/saphelp_nw2004s/helpdata/en/95/5a08cd0e274a0bae559622d6670722/frameset.htm
    Could anyone provide the complete manual of SAP Query Creation
    Tcode is : SFP
    chk these links:
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/d4fe7fca-0b01-0010-569a-9a9c1ddf4132
    https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/7c3bc67e-0c01-0010-dbb3-908315896909 [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/7c3bc67e-0c01-0010-dbb3-908315896909 [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    /people/vani.krishnamoorthy/blog/2006/05/17/fillable-adobe-forms-using-abap
    see these links..
    https://www.sdn.sap.com/irj/sdn/interactiveforms-elearning
    /people/thomas.jung3/blog/2005/07/13/lessons-learned-from-adobe-forms-development
    /people/community.user/blog/2006/11/20/search-help-in-isr-adobe-forms
    /people/franklin.herbas/blog/2005/12/13/2d-barcode-pdf-forms-with-sap-netweaver
    /people/vani.krishnamoorthy/blog/2006/05/17/fillable-adobe-forms-using-abap
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/849b3482206353e10000000a11466f/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/82538c0c4458bbe10000000a422035/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/46/55c841d202c317e10000000a155106/frameset.htm
    http://help.sap.com/saphelp_nw04s/helpdata/en/6d/bd2d828aa04eeb9451aad0d02ae9a0/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/dd/60694fddb74ad88cdb7d2a094f3dd2/frameset.htm
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/d4fe7fca-0b01-0010-569a-9a9c1ddf4132
    https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/7c3bc67e-0c01-0010-dbb3-908315896909 [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/7c3bc67e-0c01-0010-dbb3-908315896909 [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken] [original link is broken]
    /people/vani.krishnamoorthy/blog/2006/05/17/fillable-adobe-forms-using-abap
    https://www.sdn.sap.com/irj/sdn/interactiveforms
    http://www.sap.com/company/press/press.epx?pressID=2785
    http://www.adobe.com/enterprise/partners/sap.html
    http://www.adobe.com/enterprise/partners/pdfs/sap_datasheet.pdf

  • Horizontal Text In Template using Smartforms

    Hi Friendz,
    Im having a problem in Template using smartforms. Actually, I need a Header Caption for this with a format  :
    COMPANY      DEPT      BASIC
    so i created a text for this...
    but once i viewed the report ,the output display is in the format :
    COMPANY
    DEPT
    BASIC
    Kindly help me with my problem...output must be in a one line with 3 columns.
    What is the purpose of  append directly,new line and new paragraph in properties of Text.Is there any technik for this text?
    Thanks in advance
    aVaDuDz

    Hi,
    usually the proceddure is we have to divide the template into three parts
    now create three text elements
    and in each text give
    company
    dept
    basic
    now go to output options and
    in the bottom of it output structure will be there
    in that line 1
    column   1 for first one
    line 1 column2 for second one
    and try to give the styles form attributes
    output options tab
    style    zstyle
    i hope it works
    regards,
    venkatesh

  • Rotation of label using smartforms by 90 deg using zebra printer

    Hi,
    I am facing one problem using smartforms for label printing. Since the zebra printer which is being used requires 90 deg rotation of form for the normal smartform design. I have even tried using ZPL commands by using ^FWR  command in the window attributes but the text within that window only gets rotated and each line gets overwritten on one another. Please let me know if it s possible to rotate the complete form in smartform for label printing using zebra printer.
    Thanks and Regards
    Anand

    Hi Anand,
    Check my previous thread below about this:
    Re: print label landscape to zebra printer - text position wrong & overlapping
    regards,
    Aidan

  • *BARCODE USING SMARTFORMS*

    hi experts,
    i need examples on barcodes using smartforms......
    in smartform dev(wht are the fields to take)
    rewards points will be there....
    thanks and regards
    fareeda

    Hi Fareeda,
    To print a barcode in a smart form,you need to create a character format for the barcode.
    TO create a character format,you need to do it in SMARTSTYLES tcode.
    Follow these steps:
    Go to the SMARTSTYLES tcode.
    Give a name to your style and create it.
    Give a description and save it.
    On the left hand side of the window,you will find character formats.
    Click on it and press F5.
    Give a name to the character format and select OK.
    Give a description for the character format and save it.
    There you will find a tab by name General Settings.In that Tab you will find BarCode.
    Select any one of the style for the barcode as per your requirement.This is the name of the barcode.
    Now save the character format and activate the samrtstyle.
    To use the bar code in the form,follow these steps:
    now in the window,you will find a tab by name OUTPUT OPTIONS.Ther give the name of the style same as the name that you have created in the SMARTSTYLES.
    In the text element window,Select the character format that you have created in the smartstyles.
    Now in  the text elements of the window, type the field name for which you want to print the bar code in the following way to print the bar code:
    &<work area/table name >-<field name>&
    Regards,
    Kaushik

Maybe you are looking for