Purpose of FunctionModule FP_JOB_OPEN ,FP_JOB_CLOSE,FP_FUNCTION_MODULE_NAME

Dear Gurus,
what is the purpose of this  Function Modules.
FP_JOB_OPEN ,
FP_JOB_CLOSE,
FP_FUNCTION_MODULE_NAME
Thanks,
Rajkumar.A
Edited by: rajkumar on Dec 30, 2008 3:17 PM

Hi Raj,
The below function modules are used to send a PDF based form to a spool.  Once you design a PDF form and a interface in transaction SFP. You can use the below function modules to call the form through your application Program. If you had already worked on smartforms, then it's quite similar.
FP_OPEN_JOB is used to set the output parameters and opens the spool job
FP_FUNCTION_MODULE_NAME is to get the generated function module by inputting a FORM name
FP_JOB_CLOSE is to close the spool
Thanks!

Similar Messages

  • Error 101 using fp_job_open, fp_job_close in a function module

    I have earlier made a program generating a pdf used for printing. Used fp_job_open -> Call function xxx -> fp_job_close. This program works fine.
    Now I want to make a function module to generate this pdf for higher reusability, but when I call my generated FM its return sy-subrc = 1 and sy-msgno = 101. As far as I have investigate this error means "Job already open".
    I tried to comment out the call to the fp_job_open and fp_job_close, but then I have no possibility to mark the ls_outputparams-getpdf = 'X' and ls_outputparams-nodialog = 'X'.
    Any ideas anyone?

    I am not sure if this is the right forum for this question. Maybe: ABAP Developmnet -> Form printing [Output Management; is more proper?

  • Can i use fp_job_open, fp_job close in one function module to get hex pdf

    Hello All,
    Can anyone help me here.
    I am trying to use function modules FP_JOB_OPEN, FP_JOB_CLOSE,FP_FUNCTION_MODULE_NAME and call generated function modules in one function module and try ing to get hex string of pdf.
    But hex string of pdf is not coming.Should i do any setting in any of the parameter so that the function module using all these function module gets the pdf hex string.
    Regards,
    Menaka.H.B

    Hello,
    do you want to get the PDF out of the printing program to use it elsewhere? (Portal, GOS etc.)
    You need to work with the CALL FUNCTION fm_name part where the output parameter of the generated function module is XSTRING type (if i remember well) and that´s a place to start. You can convert from xstring to binary and back using SCMS_XSTRING_TO_BINARY and BIN_2_SCMS.
    Also do not forget to set fp_outputparams-GETPDF = 'X'. to get the hex.
    Regards, Otto

  • Parameters of  FP_JOB_OPEN

    Hi,
    Can any body sned the SAP help URL for the following FM's
    1) FP_JOB_OPEN
    2) FP_FUNCTION_MODULE_NAME
    3) FP_JOB_CLOSE
    Regards,
    Venkat

    Hi,
    Please do a search before posting in SDN. You can also check the report programs delivered by SAP. They mostly start with 'FP'.
    I did a quic search in SDN and got this  -> https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/ebe3be21-0b01-0010-c08c-969bd98680b0
    Regarrds,
    - anto.

  • Sap Help Url's

    Hi,
    Can any body send the Sap Help Url's for adeobe form function modules individually
    i mean individual Url's for function modules
    1) FP_JOB_OPEN
    2) FP_FUNCTION_MODULE_NAME
    3) System generated function module
    4) FP_JOB_CLOSE
    Regards,
    Venkat

    Well, not sure if you saw the info here: http://help.sap.com/saphelp_nw04/helpdata/en/23/17f13a2f160f28e10000000a114084/content.htm
    But you can create the IF THEN by using ( ) in the forumla builder:
    Reqt: IF A > B THEN B + C ELSE A
    Formula: (A > B )* (B + C) + (A <= B ) * A
    Each expression in the ( ) is evaluated as True or False and accordingly outputs 1 or 0.
    Hope this helps...

  • Need help on adobe form

    Iam new to adobe form..i studied all the documents available on adobe form....but still i have some doubts..plz clarify these.....
    1)if i want to attach one adobe form to one transaction where can i attach my adobe form?
    2)when we write driver program for one form ...how could we call that in program?
    3)how can we calculate totals in adobe form?
    plz help me.....iam waiting for your valuable replies...

    Pl. see my answers below...
    1)if i want to attach one adobe form to one transaction where can i attach my adobe form?
    If ur transaction supports message control technique then u can attach a PDF form and its driver prog. name with an output type from transaction NACE.
    2)when we write driver program for one form ...how could we call that in program?
    U have to use fms  like FP_FUNCTION_MODULE_NAME','FP_JOB_OPEN','FP_JOB_CLOSE'
    to call the form.
    First get name of the generated function module*
    call function 'FP_FUNCTION_MODULE_NAME'
      EXPORTING
        i_name     = p_form
      IMPORTING
        e_funcname = fm_name.
    if sy-subrc <> 0.
      message e001(FP_EXAMPLE).
    endif.
    Set output parameters and open spool job*
    fp_outputparams-nodialog = 'X'.    " suppress printer dialog popup*
    fp_outputparams-preview  = 'X'.    " launch print preview*
    call function 'FP_JOB_OPEN'
      CHANGING
        ie_outputparams = fp_outputparams
      EXCEPTIONS
        cancel          = 1
        usage_error     = 2
        system_error    = 3
        internal_error  = 4
        others          = 5.
    Set form language and country (->form locale)*
    fp_docparams-langu   = Language.
    fp_docparams-country = country.
    *fp_docparams-langu   = 'E'.
    *fp_docparams-country = 'GB'.
    currency key dependant summing*
    loop at bookings into l_booking.
      l_sums-forcuram  = l_booking-forcuram.
      l_sums-forcurkey = l_booking-forcurkey.
      collect l_sums into t_sums.
    endloop.
    Now call the generated function module*
    call function fm_name
      exporting
        /1bcdwb/docparams        = fp_docparams
        customer                 = customer
        bookings                 = bookings
        connections              = connections
        t_sums                   = t_sums
      exceptions
        usage_error              = 1
        system_error             = 2
        internal_error           = 3
        others                   = 4.
    if sy-subrc <> 0.
      call function 'FP_GET_LAST_ADS_ERRSTR'
        IMPORTING
          e_adserrstr = error_string.
      if not error_string is initial.
        we received a detailed error description*
        write:/ error_string.
        exit.
      else.
        message id sy-msgid type sy-msgty number sy-msgno
                with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      endif.
    endif.
    Close spool job*
    call function 'FP_JOB_CLOSE'
      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.
    For details see the std. example prog. FP_EXAMPLE_01.
    3)how can we calculate totals in adobe form?
    Within the form interface u can calculate it or u can use the Javascript or formcalc scripting language to do the same.
    Regards,
    Joy.

  • Adobe form: all employees  list in a single pdf----URGENT

    Hi experts,
    I have one adobe form, which is giving output correctly.
    input : 10 employees.
    output in pdf : pdf is coming in output.if i want to save the file, each employee data is storing in a separate file.
    my requirement : i need to save all the employees data into one pdf file.
    Thanks in advance
    Correct answers will be rewarded.
    dasrreddy
    Edited by: dasr r on May 7, 2008 3:12 PM

    Hi,
    you mighit be calling the function module FP_JOB_OPEN and FP_JOB_CLOSE in the loop as follows.
    loop at employee.
    FP_JOB_OPEN
    FP_JOB_CLOSE.
    endloop.
    Instead of this write as follows.
    FP_JOB_OPEN
    loop at employee.
    endloop.
    FP_JOB_CLOSE.
    Thanks,
    NN.

  • Regarding se38 to adobe forms

    Dear all
    I hav created one adobe  form connected with SE38..
           CALL FUNCTION 'FP_JOB_OPEN'
            call  FP_FUNCTION_MODULE_NAME
            call fm_name
    Above the FM i used for call the adobe . while execute it will ask for output device popup as ZLEX610... its working fine.
    How we can restrict that pop up ( output device pop up )....
    How we can give that zlex610 output deveice dynamically.....
    Kindly help
    Thakns

    Hi Irfan,
    set your default printer in user setting .
    then it will not ask to enter the printer when you execute adobe form
    go to system -> user profile -> own data
    set your defualt printer.
    Regards,
    Vijay

  • ADS: SOAP Runtime Exception

    Hi All
       I am trying to excute adobe form using function modules fp_job_open , fp_job_close and the function module for adobe form inside a custom program.
    when I run the program it gives the below error message
    "ADS: SOAP Runtime Exception: CSoapExceptionTransport :(100101)" .
    why does this error come . How to resolve this issue.
    Regards

    Hello;
    I am new to Interactive Forms by ADOBE, but I did run into this error when trying to activate a form. SAP told me  to run test according to note 944221 and config RFC connection to ADS. Then we fixed-The two users for Adobe (ADSUSER & ADS_AGENT) were set as dialog users. 
    This dorrected the issue.

  • Adobe Form assignment

    Hi there,
    We're doing ECC 5.0 implementation at the moment and starting to use adobe form for our form printing document out of SAP.
    As you know previously with SAPScript or SmartForms, that we normally assign print program and form into Output Control/Messages etc in SAP Configuration (SPRO trasnsaction).
    What about with Adobe Form ? For the example for Work Order in Plant Maintenance. Under configuration is pointing to SapScript form, Print Program and Routine name.
    I created one program to call the Adobe Form (FP_JOB_OPEN, FP_JOB_CLOSE, etc) and assign into the configuration to call up this program and Adobe form. Is it the right way ?
    One more question, under transaction SFP, Utilities->Download form Object ... what is this for ? As I tried to use this to download the form to my local PC. When I uploaded into different ECC 5.0 system with the same menu path, I got an error said : "Error occured when upload file (unknown file format).
    Thanks in advance for any help.
    Cheers,
    Danny

    HI Markus,
    the same Problem what Danny has with the Download Error, occurs in our environment too.
    When we want to upload a Form from Transaction SFP (Form Builder) following Error occur:
    "Error occurred when uploading file (unknown file format)
    Message no. FPUIFB068"
    then we download the Form Objekt "F140_CASH_DOC_01"
    it was written correctly on my Local Drive with the ending "SFPF_F140_CASH_DOC_01.XML".
    Then i wanted to Updold the file, which i dowloaded earlier then it says:
    "Error occurred when uploading file (unknown file format)
    Message no. FPUIFB068"
    we are using ERP2005 Rel. SAP ECC 6.0
    Hope to hear a solution for my problem.
    thank + regards
    I.Ismail

  • Combine Spool Job Contents ..

    Hello Experts,
    I'm hoping someone can help with this.  I have a requirement to create adobe print forms for a set amount of employees.  The problem I'm having is that I can get the spool job to create.  In side the spool job, it is broken into parts.  The pdf form created is 8 pages for one employee.  If I print 5 employees, the spool job will have 40 pages, but the job is split into 5 segments of 8 pages.  The issue I'm having is that I need to get all 40 pages in one file to send to a printer.  I've tried a number of things but I can't seem to get the spool job to print to pdf on a local machine.  The only alternative I can find is to get the segments of the spool job into one big file.
    Does anyone have any experience with this?  Points will be awarded for any help.
    Thanks,
    Meezy

    Hi,
    i have the same problem than the original poster. I call FP_JOB_OPEN/FP_JOB_CLOSE only once, and only one spool job is created. But inside this job there are several parts and each part is an own pdf document. It is possible to read each part/file separately, but i found no possibility to get one big pdf with all parts.
    Does anybody have an idea how to solve this?
    Jan

  • Print multiple forms between FP_JOB_OPEN and FP_JOB_CLOSE

    I am aware, that there are questions regarding "Printing Multiple forms", but I didn't find answers there.
    Still my system is not working as expected:
    1.  FP_JOB_OPEN is called
    2. the generated Adobe Forms function is called multiple times
    3.  FP_JOB_CLOSE is called
    This program doesn't deliver all the pages, but just the first call. How shall I solve this problem?
    (Coding should work anywhere with copy-pase.)
    data: fm_name           type rs38l_fnam,
          fp_docparams      type sfpdocparams,
          fp_outputparams   type sfpoutputparams.
    parameters: p_fpname type fpname default 'FP_TEST_02'.
    * Get the name of the generated function module
    call function 'FP_FUNCTION_MODULE_NAME'
      exporting
        i_name     = p_fpname
      importing
        e_funcname = fm_name.
    * Sets the output parameters and opens the spool job
    call function 'FP_JOB_OPEN'
      changing
        ie_outputparams = fp_outputparams
      exceptions
        cancel          = 1
        usage_error     = 2
        system_error    = 3
        internal_error  = 4
        others          = 5.
    * Call the generated function module
    call function fm_name.
    * SECOND CALL ****************************
    call function fm_name.
    * Close the spool job
    call function 'FP_JOB_CLOSE'
    *    IMPORTING
    *     E_RESULT             =
      exceptions
        usage_error           = 1
        system_error          = 2
        internal_error        = 3
        others               = 4.

    Hi ZSOLT,
    In order to call the form multiple times please do the following,
    1) Just before your FP_JOB_OPEN you need to pass the output parameters (good practice). You can also set other parameters as well (for example nodialog, preview, copies., etc)
      CLEAR  fp_outputparams.
      fp_outputparams-dest = 'PDF1'.      "Default pdf printer
      fp_outputparams-reqnew = 'X'.       "New spool request
    Now call your FM FP_JOB_OPEN with the above output parameters.
    2) Usually this step is processed in a loop. (getting your interface data into a internal table and then looping at it)
    But here I am enhancing your example code.
    In order to trigger the form multiple times you need to change some input data to the form (for example I have changed date and time below in the prepare test data sections) so that the call function fm_name gets regenerated every time there is new data
    data  l_datatypes       type sfpdatatypes.
    prepare test data
      l_datatypes-char = '#'.
      l_datatypes-string = 'Auf geht''s! '.    "#EC NOTEXT
      l_datatypes-numc = '42'.
      l_datatypes-dec = 0 - ( 12345 / 7 ).
      l_datatypes-fltp = 0 - ( 12345 / 7 ).
      l_datatypes-int = 4711.
      l_datatypes-curr = 0 - ( 12345 / 7 ).
      l_datatypes-cuky = 'JPY'.       " no decimals
      l_datatypes-quan = 12345 / 7.
      l_datatypes-unit = 'DEG'.       " 1 decimal
      l_datatypes-date = '20040613'.      
      l_datatypes-time = '100600'.         
      l_datatypes-lang = sy-langu.
    FIRST CALL ****************************
    Call the generated function module
      CLEAR fp_docparams.
      fp_docparams-langu = 'EN'.       
      fp_docparams-country = 'US'.  
      call function fm_name
        exporting
          /1bcdwb/docparams        = fp_docparams
          datatypes                = l_datatypes
          mychar                   = l_datatypes-char
         mybyte                   =
          mystring                 = l_datatypes-string
         myxstring                =
          mydate                   = l_datatypes-date
          mytime                   = l_datatypes-time
          mynum                    = l_datatypes-numc
          myint                    = l_datatypes-int
          myfloat                  = l_datatypes-fltp
          mypacked                 = l_datatypes-dec
      IMPORTING
        /1BCDWB/FORMOUTPUT       =
    prepare test data
      l_datatypes-char = '#'.
      l_datatypes-string = 'Auf geht''s! '.    "#EC NOTEXT
      l_datatypes-numc = '42'.
      l_datatypes-dec = 0 - ( 12345 / 7 ).
      l_datatypes-fltp = 0 - ( 12345 / 7 ).
      l_datatypes-int = 4711.
      l_datatypes-curr = 0 - ( 12345 / 7 ).
      l_datatypes-cuky = 'JPY'.       " no decimals
      l_datatypes-quan = 12345 / 7.
      l_datatypes-unit = 'DEG'.       " 1 decimal
      l_datatypes-date = '20100913'.                 "You need to change your data in order it to trigger a new form with the new data.
      l_datatypes-time = '10700'.                        "You need to change your data in order it to trigger a new form with the new data.       
      l_datatypes-lang = sy-langu.
    SECOND CALL ****************************
    Call the generated function module
      CLEAR fp_docparams.
      fp_docparams-langu = 'EN'.
      fp_docparams-country = 'US'.
      call function fm_name
        exporting
          /1bcdwb/docparams        = fp_docparams
          datatypes                = l_datatypes
          mychar                   = l_datatypes-char
         mybyte                   =
          mystring                 = l_datatypes-string
         myxstring                =
          mydate                   = l_datatypes-date
          mytime                   = l_datatypes-time
          mynum                    = l_datatypes-numc
          myint                    = l_datatypes-int
          myfloat                  = l_datatypes-fltp
          mypacked                 = l_datatypes-dec
      IMPORTING
        /1BCDWB/FORMOUTPUT       =
    Close the spool job
    call function 'FP_JOB_CLOSE'
       IMPORTING
        E_RESULT             =
      exceptions
        usage_error           = 1
        system_error          = 2
        internal_error        = 3
        others               = 4.
    I have tested the above code and I am getting multiple forms.
    Please try on your end and let me know if it works.
    Thanks
    Raj

  • Error in Using FP_JOB_OPEN

    Hi all,
    I am using FP_JOB_OPEN FM to open a PDF form in EP.
    But I am getting an error stating that "Define all the required parameters".
    Please help me on this.
    Regards,
    Amit

    Hi Markus,
    I was trying to open a simple print form, previously I had not defined the connection field in SFPOUTPUTPARAMS
    Now PDF is not giving any error. But nothng is coming up, neither the error nor the form.
    This is the code I have written :
      DATA : lv_fname            TYPE  funcname,
             lt_ie_outputparams  TYPE  sfpoutputparams,
             lt_pernr            TYPE  qisr_tab_type,
             lt_ename            TYPE  qisr_tab_type,
             ls_special_data     LIKE LINE OF special_data,
             ls_pernr            LIKE LINE OF lt_pernr,
             ls_ename            LIKE LINE OF lt_ename.
      DATA fp_docparams TYPE sfpdocparams .
      DATA fp_formoutput TYPE fpformoutput .
      DATA t_head TYPE thead .
       CALL FUNCTION 'FP_FUNCTION_MODULE_NAME'
            EXPORTING
              i_name                     = 'Z_ISR_FORM_TEST1'
            IMPORTING
              e_funcname                 = lv_fname
            E_INTERFACE_TYPE           =     .
          lt_ie_outputparams-nodialog = 'X'.
          lt_ie_outputparams-getpdf = 'X'.
          lt_ie_outputparams-connection = 'ADS'.
          CALL FUNCTION 'FP_JOB_OPEN'
            CHANGING
              ie_outputparams = lt_ie_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.
          fp_docparams-langu = 'E'.
          fp_docparams-country = 'GB'.
          fp_docparams-fillable = ''.
        fp_docparams-fillable = 'X'.
          CALL FUNCTION lv_fname
            EXPORTING
              /1BCDWB/DOCPARAMS        = fp_docparams
              pernr                    = lt_pernr
              ename                    = lt_ename
          IMPORTING
            /1BCDWB/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.

  • Problem while calling the FM FP_JOB_OPEN

    Hi All,
    I have a scenario where i need to attach multiple Forms(Adobe) to a work flow container.
    While calling the FM 'FP_JOB_OPEN', i am passing the required parameters as below
    wl_outputparams-nodialog = 'X'.
    wl_outputparams-connection = 'ADS'.
    wl_outputparams-dest = 'LP01'.
    wl_outputparams-getpdf  = 'X'.
    the problem is that i get a Print preview pop-up even though i pass Nodialog = 'X', and more over after calling the actual Form function module the resultant parameter 'fpformoutput-pdf' is only filling up only after i process the print preview dialog and see the preview. other wise the field 'fpformoutput-pdf' is blank.
    as i need to do this work in back ground(for work flow background step) i do not want the print preview pop-up window.
    can some one help me in this regard.
    PS. For multiple forms i tried calling the form functions modules in between every FP_JOB_OPEN n FP_JOB_CLOSE
    as well as a single FP_JOB_OPEN and calling the multiple form function modules and FP_JOB_CLOSE.
    thanks in anticipation .
    Srinivas

    @koolspy      
    Yes, i did specify the settings in the o/p options.
    in addition to this, after debugging i could able to see some issue when calling form name via  FM 'FP_FUNCTION_MODULE_NAME', in this FM it is appending '_IN' to the generated FM name and trying to check for existence check, obviously there wont be any FM as it is appending '_IN' to the generated FM.
    but when calling the generate FM after FP_JOB_OPEN it is throwing sy-subrc = 1, which is Usage error.
    Why is it behaving weirdly, is there any thing i am missing while calling the Form?
    please help as this is on high priority
    thanks
    srinivas

  • Curiosity: How to use a table for input when testing a functionmodule?

    actually I am sick of writing test programs for every function I want to test using ABAP.
    So why it is (made) impossible to generate input data for a table as input parameter of a functionmodule?
    Has really nobody ever tested this stuff when the test function was implemented in SE37 or was this bug implemented on purpose to generate work?

    Andreas,
    You can input data into the internal table by:
    Test FM
    > Testing initial screen --- click on the table icon against your table parameter
    > Input your input data in the fields
    > to Input more lines in the table.. press Insert Line (icon with plus sign)
    After this press back button.
    Now, you will have your test data in the tables.
    Regards,
    Naimesh

Maybe you are looking for

  • Problem Adding Audio to iMovie (Filevault Problem?)

    Ok... I made an iMovie project when I returned from a trip.  I then turned on Filevault in Lion for full disk encryption (I've been waiting for this feature because I need it for my business).  I went back to make some edits in my video... and iMovie

  • Activate CRM_30A_USER_EXITS

    Hi, Are there any BADI / user exits which will trigger during the transfer of master data (BP)  from CRM middleware to r/3 systems in SAP CRM 4.0. Actually I have a requirement in which I have to assign the DATA_KEY-IDENTIFICATIONNUMBER of the IDENT_

  • How to make Java Application a System Service.!

    Hi, I am developing an application in Java, which I wolud like to run as a System service in Windows or as a Background process in Unix/Linux. I am using JDK 1.3.1. Can anybody help me with this? Thank you, Manish.

  • Date display problem "Arabic"

    I am currently facing a problem related to date display as the date is being displayed in the following format: ������ 01, 2007 I have checked the Locale and it was en_US. Can someone help me out so that the format that I get is the following: Sept 0

  • HT4623 i have reset factory setting so how do i activate my phone now?

    i have reset factory setting so how do i activate my phone now?