How to use BOR in my program

Hi Exprets,
I want to use a BOR(INSTLN) to update data of an installation, but I do not know how to use a BOR in my program, how to declare it, how to use the methods of the BOR. I would be appreciated if some1 give me some sample code.
Points will be rewarded, Thx in advance.
Vincent

Hi,
Look this code, hopefully can help you:
Declaration:
INCLUDE  <CNTN01>.
* BOR
SWC_CONTAINER CON.
DATA: REQ   TYPE SWC_OBJECT.
Bor Initialization:
Bor Name: 'ZHRQ295O'.
WA_HEADER-DOCNO is key field for BOR 'ZHRQ295O'.
You have to see your BOR key fields.
*&      Form  INIT_OBJECT
FORM INIT_OBJECT.
  SWC_CREATE_CONTAINER CON.
  SWC_CREATE_OBJECT REQ 'ZHRQ295O' WA_HEADER-DOCNO.
ENDFORM.                    " INIT_OBJECT
Calling method in BOR:
Statement 'SWC_SET_ELEMENT' is for give BOR attributes value.
*&      Form  CALL_REQUEST
FORM CALL_REQUEST.
  SWC_CLEAR_CONTAINER CON.
  SWC_SET_ELEMENT CON 'DocStatus'  WA_HEADER-DOCSTATUS.
  SWC_CALL_METHOD REQ 'Post' CON.
ENDFORM.                    " CALL_REQUEST
Clear/Delete BOR:
*&      Form  RELEASE_OBJECT
FORM RELEASE_OBJECT .
  SWC_RELEASE_CONTAINER CON.
  SWC_FREE_OBJECT REQ.
ENDFORM.                    " RELEASE_OBJECT
Regards,

Similar Messages

  • How to use upload condition record program RV14BTCI

    Hi
    how to use upload condition record program RV14BTCI.
    kathir.

    Hi,
    To run this program we have to maintain Upload file in Application Directory,
    We have to maintain 3 levels of records in that file.. my feel you upload through BDC or LSMW.
    For your information,
    The batch input program RV14BTCI reads the parameters is necessary
    Giving sequential file and creates (depending on the data
    In the file seq) one or more batch input sessions.
    The data are seq file in the following structure expected:
    - The session a session intent (Table KOBTCI, Record 0)
    All other records until the next session, the intent
    Last session assigned to read
    - The head condition Sentence (Table KOBTCI, record 1)
    All other records until the next condition,
    Last read head appropriate rate
    This includes the corresponding condition
    Condition table
    - The key sentence of a Main (Table KOBTCI, record 2)
    It must be directly on the head set to follow
    It contains the key condition of the table
    + Detail fields
    - The season record has a subordinate clause (Table KOBTCI, record 3)
    The teams relate to the key sentence in the main
    Best Regards,
    KSK

  • How to use Enhancement spot in program

    Hi gurus,
    now i am working ecc 6.0, so how to use Enhancement spot in program, can anybody explain step by step.
    Rewarded with points.
    Thanks
    Naveen

    Hi Naveen ,
    Enhancement Spot are available.
    Examples:
    -End of Executable Program, Include, Function group, Dialog module
    -Begin/End of Form routine / Function module / Method
    -End of a structure
    -End of Private/Protected/Public Section of a local class
    If you want to create Implementation , You have to right click on yellow color line and gve Zxxx and save it in any
    transport request under any dev class. Then you can write your own code and save it and activate it .
    Later If you want to Transport it you need to transport this request.
    Reqward if usefuil
    Thanks
    Jagadeesh.G

  • How to use ComponentWork CWSerial to program such thing like HyperTerminal does to communicate 2 PCs through its RS232?

    Right now I use null modem cable, I can communicate 2 PCs use hyper-terminal. I wonder how to use ComponentWork CWSerial to program such kind of job? Thanks!

    Hi Kevin,
    Of course this will take a little work, but CWSerial should be able to handle this without too much hassle. Take a look at the example program usually included in C:\Program Files\National Instruments\MeasurementStudio\VB\Samples\Instr\Basic Serial
    You should be able to use this example as a starting point.
    Hope this helps out!!!
    Best Regards,
    Aaron Kobayashi
    Application Engineer
    National Instruments

  • How to use ranges in the program

    hi all,
    my requirement is i need to create a range for srat date so iam creating a structure say name of the range table is zstartdate. how to use this table in my program.
    selct * from zuser_Secobjects where start_date in zstartdate. is it ok ?
    thanks
    maheedhar.t

    hi maheedhar,
    I am sending u the sample program and the docs also.
    Program:
                    T A B L E  D E C L E R A T I O N                     *
    **-- Tables used
    **-- VBAK.    "Sales Document: Header Data
                      T Y P E  D E C L E R A T I O N                     *
    **-- Type for VBAK
    TYPES: BEGIN OF T_VBAK,
          VBELN LIKE VBAK-VBELN,
          ERDAT LIKE VBAK-ERDAT,
          AUART LIKE VBAK-AUART,
          END OF T_VBAK.
           I N T E R N A L  T A B L E  D E C L E R A T I O N             *
    **-- Internal table to store header data
    DATA: IT_VBAK TYPE STANDARD TABLE OF T_VBAK WITH HEADER LINE.
    **-- Ranges for Inquiry/Quotation
    RANGES R_AUART FOR VBAK-AUART.
           C O N S T A N T S           D E C L E R A T I O N             *
    **-- Constant to store value of Inquiry (IN) / Quotation (QT).
    CONSTANTS: C_IN LIKE VBAK-AUART VALUE 'AF',
               C_QT LIKE VBAK-AUART VALUE 'AG',
               C_EQ(4) TYPE C VALUE 'EQ',
               C_I(2) TYPE C VALUE 'I'.
                         I N I T I A L I Z A T I O N                     *
    **-- Clear the internal tables and flag.
    CLEAR: IT_VBAK,
           R_AUART.
    **-- Refresh the internal tables.
    REFRESH: IT_VBAK,
             R_AUART.
    **-- Initialization of ranges
    R_AUART-SIGN = C_I.
    R_AUART-OPTION = C_EQ.
    R_AUART-LOW = C_IN.
    APPEND R_AUART.
    CLEAR R_AUART.
    R_AUART-SIGN = C_I.
    R_AUART-OPTION = C_EQ.
    R_AUART-LOW = C_QT.
    APPEND R_AUART.
    CLEAR R_AUART.
                S E L E C T I O N  S C R E E N                           *
    SELECTION-SCREEN BEGIN OF BLOCK CHARLY WITH FRAME TITLE TEXT-001.
    SELECT-OPTIONS: S_VBELN FOR IT_VBAK-VBELN OBLIGATORY.
    SELECT-OPTIONS: S_ERDAT FOR IT_VBAK-ERDAT.
    SELECTION-SCREEN END OF BLOCK CHARLY.
      A T  S E L E C T I O N  S C R E E N ( V A L I D A T I O N S )      *
    AT SELECTION-SCREEN.
    **-- Check the sales order number exists in the database table or not
      SELECT SINGLE VBELN
                    FROM VBAK
                    INTO IT_VBAK
                    WHERE VBELN IN S_VBELN
                      AND ERDAT IN S_ERDAT
                      AND AUART IN R_AUART.
    **-- If no single data selected display error message.
      IF SY-SUBRC <> 0.
        MESSAGE E000.
      ENDIF.
                   S T A R T  O F  S E L E C T I O N                     *
    START-OF-SELECTION.
    **-- To fetch data from database table (VBAK)
    **-- Store the data into the internal tabe (IT_VBAK)
      PERFORM ZF_GETDATA.
                     E N D  O F  S E L E C T I O N                       *
    END-OF-SELECTION.
    **-- To display sales order.
      PERFORM ZF_CHECK_DISPLAY.
                            T O P  O F  P A G E                         *
    TOP-OF-PAGE.
    **-- Page header
      PERFORM ZF_TOP_OF_PAGE.
                            E N D  O F  P A G E                         *
    END-OF-PAGE.
    **-- Page footer
      PERFORM ZF_END_OF_PAGE.
    *&      Form  ZF_GETDATA
          text
    -->  p1        text
    <--  p2        text
    FORM ZF_GETDATA .
      SELECT VBELN
             ERDAT
             AUART
             INTO TABLE IT_VBAK
             FROM VBAK
             WHERE VBELN IN S_VBELN
                   AND ERDAT IN S_ERDAT
                   AND AUART IN R_AUART.
      IF SY-SUBRC <> 0.
        MESSAGE S001 WITH IT_VBAK-VBELN.
      ELSE.
        SORT IT_VBAK.
      ENDIF.
    ENDFORM.                    " ZF_GETDATA
    *&      Form  ZF_CHECK_DISPLAY
          text
    -->  p1        text
    <--  p2        text
    FORM ZF_CHECK_DISPLAY .
      CLEAR: IT_VBAK.
       LOOP AT IT_VBAK.
      IF IT_VBAK-AUART = C_IN.
        ULINE.
        WRITE:/1 SY-VLINE, 10 TEXT-006 INVERSE COLOR COL_HEADING,
               50 TEXT-007 INVERSE COLOR COL_HEADING,
               143 SY-VLINE.
          WRITE:/1 SY-VLINE,12 IT_VBAK-VBELN INVERSE COLOR COL_NORMAL,
                 52 IT_VBAK-ERDAT INVERSE COLOR COL_NORMAL,
                 143 SY-VLINE.
      ENDIF.
      IF IT_VBAK-AUART = C_QT.
        ULINE.
        WRITE:/1 SY-VLINE, 10 TEXT-008 INVERSE COLOR COL_HEADING,
                50 TEXT-007 INVERSE COLOR COL_HEADING,
                143 SY-VLINE.
          WRITE:/1 SY-VLINE,12 IT_VBAK-VBELN INVERSE COLOR COL_NORMAL,
                 52 IT_VBAK-ERDAT INVERSE COLOR COL_NORMAL,
                 143 SY-VLINE.
      ULINE.
      ENDIF.
       ENDLOOP.
    ENDFORM.                    " ZF_CHECK_DISPLAY
    *&      Form  ZF_TOP_OF_PAGE
    Header of the page gets displayed as soon as a new page is generated
    FORM ZF_TOP_OF_PAGE .
      ULINE.
      WRITE:/1 SY-VLINE, 5 TEXT-002 INVERSE COLOR 7,143 SY-VLINE.
      WRITE:/1 SY-VLINE, 143 SY-VLINE .
      WRITE:/1 SY-VLINE, 30 TEXT-003 INVERSE COLOR 7,143 SY-VLINE.
      WRITE:100 TEXT-004 INVERSE COLOR 7,120 SY-DATUM INVERSE COLOR 7,
      143 SY-VLINE.
      WRITE:/1 SY-VLINE,100 TEXT-005 INVERSE COLOR 7,
      120 SY-PAGNO INVERSE COLOR 7,143 SY-VLINE.
      ULINE.
    ENDFORM.                    " ZF_TOP_OF_PAGE
    *&      Form  ZF_END_OF_PAGE
    Footer text displayed in each page
    FORM ZF_END_OF_PAGE .
      WRITE:/60 TEXT-008.
    Docs:
                                           Ranges
    A selection table is linked to the column of a database table, or to an internal field in the program. A selection table is an internal table object of the standard table type that has a standard key and a header line.
    In addition to selection tables that we create using SELECT-OPTIONS, we can use the RANGES statement to create internal tables that have the structure of selection tables. You can use these tables with certain restrictions the same way you use actual selection tables.
    A ranges table type is a special case of a table type. A ranges table type describes the structure of an internal table for administrating complex areas, i.e. the type of an internal table ranges table in the ABAP program.
    The row type of a ranges table type has a fixed structure. The row type consists of 4 components SIGN (sign), OPTION (comparison operator), LOW (lower limit) and HIGH (upper limit) in this order.
    1.     SIGN – The database type of SIGN is C with length 1. The contents of SIGN determine for each row whether the result of the row condition is to be included in or excluded from the resulting set of all rows. Possible values are I (inclusion criterion – operators are not inverted) and E (exclusion criterion – operators are inverted).
    2.      OPTION – The database type OPTION is C with length 2. It contains the selection operator. The following operators are available:-
    -     If HIGH is empty, we can use EQ, NE, GT, LE, LT, CP, and NP.
    -     CP and NP are only allowed if wildcards (‘*' or '+’) are used in the input fields.
    -     If wildcards are entered on the selection screen, the system automatically uses the operator CP. The escape character is defined as #.
    -      If HIGH is filled, you can use BT (Between) and NB (Not Between). We cannot use wildcard characters.
    3.     LOW - The data type of LOW is the same as the column type of the              database table, to which the selection criterion is linked.
    – If HIGH is empty, the contents of LOW define a single field comparison. In combination with the operator in OPTION, it specifies a condition for the database selection.
    –     If HIGH is filled, the contents of LOW and HIGH specify the upper and lower limits for a range. In combination with the operator in OPTION, the range specifies a condition for the database selection.
    4.     HIGH - The data type of HIGH is the same as the column type of the database table, to which the selection criterion is linked. The contents of HIGH specify the upper limit for a range selection.
    If the selection table contains more than one row, the system applies the following rules when creating the complete selection criterion:
    1.     Form the union of sets defined on the rows that have SIGN field equal to I (inclusion).
    2.     Subtract the union of sets defined on the rows that have SIGN field equal to E (exclusion).
    3.     If the selection table consists only of rows in which the SIGN field equals E, the system selects all data outside the set specified in the rows.
    RANGES tables
    We can use the following variants of the TYPES and DATA statements to create internal tables of the same type as selection tables.
    TYPES|DATA .
    An elementary associated type defines the type of components LOW and HIGH. It can be defined by specifying a data element or by directly defining the data type, number of places and if necessary the number of decimal places.
    A ranges table type always has Standard table access mode and a standard key that is non-unique.
    I think this will help u .
    Reward points if helpful.
    Regards
    Nilesh

  • How to use RSAN_PROCESS_EXECUTE in abap program

    Hi all,
    Does someone know how to use RSAN_PROCESS_EXECUTE in a abap program to execute an analytical process created in the transaction RSANWB?
    I create a variant 'ZPC_ALIM_DL' for RSAN_PROCESS_EXECUTE. I would like to execute this program with this variant in a background job, but it seems that the job executed but it does nothing.
    See below a part of the code.
    SUBMIT RSAN_PROCESS_EXECUTE
                 WITH VARIANT = 'ZPC_ALIM_DL'
                 USER SY-UNAME VIA JOB L_JOBNM1 NUMBER L_JOBCOUNT1
                 AND RETURN.
    Thanks in advance,
    L.

    Hi Ludovic,
              I am using RSAN_PROCESS_EXECUTE with a variant in process chain. simply include 'abap program' type in process chain mention RSAN_PROCESS_EXECUTE as the program name and mention the variant you created for your apd process and run. I have tested it in dev and it has worked for me. let me know if this helps!
    Thanks
    Suresh R Kovvuru

  • How to use field symbols in program

    how to use field symbols can any one explain with example please..
    Regards,
    venki...

    Hi
    Field Symbols
    Field symbols are placeholders or symbolic names for other fields. They do not physically reserve space for a field, but point to its contents. A field symbol cam point to any data object. The data object to which a field symbol points is assigned to it after it has been declared in the program.
    Whenever you address a field symbol in a program, you are addressing the field that is assigned to the field symbol. After successful assignment, there is no difference in ABAP whether you reference the field symbol or the field itself. You must assign a field to each field symbol before you can address the latter in programs.
    Field symbols are similar to dereferenced pointers in C (that is, pointers to which the content operator * is applied). However, the only real equivalent of pointers in ABAP, that is, variables that contain a memory address (reference) and that can be used without the contents operator, are reference variables in ABAP Objects.
    All operations programmed with field symbols are applied to the field assigned to it. For example, a MOVE statement between two field symbols moves the contents of the field assigned to the first field symbol to the field assigned to the second field symbol. The field symbols themselves point to the same fields after the MOVE statement as they did before.
    You can create field symbols either without or with type specifications. If you do not specify a type, the field symbol inherits all of the technical attributes of the field assigned to it. If you do specify a type, the system checks the compatibility of the field symbol and the field you are assigning to it during the ASSIGN statement.
    Field symbols provide greater flexibility when you address data objects:
    If you want to process sections of fields, you can specify the offset and length of the field dynamically.
    You can assign one field symbol to another, which allows you to address parts of fields.
    Assignments to field symbols may extend beyond field boundaries. This allows you to address regular sequences of fields in memory efficiently.
    You can also force a field symbol to take different technical attributes from those of the field assigned to it.
    The flexibility of field symbols provides elegant solutions to certain problems. On the other hand, it does mean that errors can easily occur. Since fields are not assigned to field symbols until runtime, the effectiveness of syntax and security checks is very limited for operations involving field symbols. This can lead to runtime errors or incorrect data assignments.
    While runtime errors indicate an obvious problem, incorrect data assignments are dangerous because they can be very difficult to detect. For this reason, you should only use field symbols if you cannot achieve the same result using other ABAP statements.
    For example, you may want to process part of a string where the offset and length depend on the contents of the field. You could use field symbols in this case. However, since the MOVE statement also supports variable offset and length specifications, you should use it instead. The MOVE statement (with your own auxiliary variables if required) is much safer than using field symbols, since it cannot address memory beyond the boundary of a field. However, field symbols may improve performance in some cases.
    check the below links u will get the answers for your questions
    http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3860358411d1829f0000e829fbfe/content.htm
    http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/field_sy.htm
    http://searchsap.techtarget.com/tip/1,289483,sid21_gci920484,00.html
    Syntax Diagram
    FIELD-SYMBOLS
    Basic form
    FIELD-SYMBOLS <fs>.
    Extras:
    1. ... TYPE type
    2. ... TYPE REF TO cif
    3. ... TYPE REF TO DATA
    4. ... TYPE LINE OF type
    5. ... LIKE s
    6. ... LIKE LINE OF s
    7. ... TYPE tabkind
    8. ... STRUCTURE s DEFAULT wa
    The syntax check performed in an ABAP Objects context is stricter than in other ABAP areas. See Cannot Use Untyped Field Symbols ad Cannot Use Field Symbols as Components of Classes.
    Effect
    This statement declares a symbolic field called <fs>. At runtime, you can assign a concrete field to the field symbol using ASSIGN. All operations performed with the field symbol then directly affect the field assigned to it.
    You can only use one of the additions.
    Example
    Output aircraft type from the table SFLIGHT using a field symbol:
    FIELD-SYMBOLS <PT> TYPE ANY.
    DATA SFLIGHT_WA TYPE SFLIGHT.
    ASSIGN SFLIGHT_WA-PLANETYPE TO <PT>.
    WRITE <PT>.
    Addition 1
    ... TYPE type
    Addition 2
    ... TYPE REF TO cif
    Addition 3
    ... TYPE REF TO DATA
    Addition 4
    ... TYPE LINE OF type
    Addition 5
    ... LIKE s
    Addition 6
    ... LIKE LINE OF s
    Addition 7
    ... TYPE tabkind
    Effect
    You can define the type of the field symbol using additions 2 to 7 (just as you can for FORM parameters (compare Defining the Type of Subroutine Parameters). When you use the ASSIGN statement, the system carries out the same type checks as for USING parameters of FORMs.
    This addition is not allowed in an ABAP Objects context. See Cannot Use Obsolete Casting for FIELD SYMBOLS.
    In some cases, the syntax rules that apply to Unicode programs are different than those for non-Unicode programs. See Defining Types Using STRUCTURE.
    Effect
    Assigns any (internal) field string or structure to the field symbol from the ABAP Dictionary (s). All fields of the structure can be addressed by name: <fs>-fieldname. The structured field symbol points initially to the work area wa specified after DEFAULT.
    The work area wa must be at least as long as the structure s. If s contains fields of the type I or F, wa should have the structure s or at least begin in that way, since otherwise alignment problems may occur.
    Example
    Address components of the flight bookings table SBOOK using a field symbol:
    DATA SBOOK_WA LIKE SBOOK.
    FIELD-SYMBOLS <SB> STRUCTURE SBOOK
    DEFAULT SBOOK_WA.
    WRITE: <SB>-BOOKID, <SB>-FLDATE.
    <b>Reward points for useful Answers</b>
    Regards
    Anji

  • How to use SUBMIT for transaction program?

    Hello,
    Please help me with following requirement.
    I need to pass selection screen values from ZReport to transaction F.01 and collect displayed data output in internal table in ZReport and use internal table for further processing.
    Please let me know,
    1) How to use SUBMIT with transaction code or modulepool program (<b>remember I don't want to submit report program</b>)?
    2) How to collect F.01 output data and bring back to Zreport ?
    Thanks in advance.

    Hi ab,
    1.  How to collect F.01 output data and bring back to Zreport
    The data (of output) can be collected,
    for display purpose.
    We cannot get the full data, which makes sense.
    2. The data shall be collected, in a printable format only,
       ie. with vertical lines, horizontal lines (if any) etc.
    regards,
    amit m.

  • How to use one forms fields, program units in another form.

    The whole proceessing and update is happening in one main form.
    Main form has all the fields and a reprocess button which re-creates records if they have error. Record name is the primary key.
    I have another small form, which just shows the list of record names in the system. I want a reprocess button next to each record name so that user will be able to just select any record name and press reprocess button to recreate any record data.
    There are a lot of fields in main form and program units , which are used by the reprocess button.
    Any suggestions like how to go for it?

    You can either pass all the relevant data from the Small Form to the Larger form and make it reprocess the data or you can move the Program Units to a PL/SQL Library (.pll) and attach the library to your smaller form where you can call the program units. Either option requires changes to the Larger form to enable it to process a record passed to the form as a parameter or to externalize the Forms Program Units to a library.
    Personaly, I would recommend you move the Program Units to a Library. This would enable you to use the processes in any form (that has the library attached).
    Hope this helps,
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

  • How to use addKeyListener in a program running using command prompt

    Does anyone have any idea how to add the addKeyListener to a program running using command prompt.
    Let me explain how the program run.
    The program is start and accept call from other program. But from time to time, I need to issue some command by pressing the keyboard, let say, ESC is closed the program, F1 is showing the stated. F2.... (This is all need to run in the command prompt windows)
    My problem is this program does not have any gui interface, so how can it be added?
    i do it this way
    public void key(){          
    addKeyListener(this);
    But it have compile error.
    mainServerImpl.java:87: cannot resolve symbol
    symbol : method addKeyListener (mainServerImpl)
    location: class mainServerImpl
    addKeyListener(this);
    I did implement KeyListener. But just don't know how to solve this error.
    can anyone tell me how to solve it or point me a source that can help.
    Thank in advance!
    Regards,
    Tai Tan

    Write your own Thread, to do this:
    public class KeyThread extends Thread {
       public void run {
          while(true) {
             int i = System.in.read();
             if(i == 123) {
                break; // to stop the thread
    // in your main:
    Thread keyThread = new KeyThread();
    keyThread.start(); // calls run() of the thread

  • How to use   RLB_INVOICE standard print program

    my program is copy of  RLB_INVOICE
    when i press execute i m not getting any output
    how can i see print preview by executing print program.

    hi,
    check this
    REPORT  ZRE_SD_INVOICE.
    *&      Form  ENTRY
          text
         -->P_ENT_RETCO   text
         -->P_ENT_SCREEN  text
    FORM ENTRY  USING    P_ENT_RETCO
                         P_ENT_SCREEN.
      DATA: lf_formname TYPE TDSFNAME,
            lf_fm_name  TYPE RS38L_FNAM,
            g_adrnr LIKE ADRC-ADDRNUMBER.
                      TABLES DECLARATIONS                                *
      TABLES: NAST,                          "Messages
              *NAST,                         "Messages
              TNAPR,                         "Programs & Forms
              ITCPO,                         "Communicationarea for Spool
              ARC_PARAMS,                    "Archive parameters
              TOA_DARA,                      "Archive parameters
              ADDR_KEY,                      "Adressnumber for ADDRESS
              T005U ,                        "FOR RETRIVAL OF STATE
              ADRC .                         "FOR RETRIVAL OF ADDRESS
                      DATA DECLARATIONS                                  *
      DATA:   RETCODE   LIKE SY-SUBRC.         "Returncode
      DATA:   XSCREEN(1) TYPE C.               "Output on printer or screen
      DATA:   REPEAT(1) TYPE C.
    DATA: NAST_ANZAL LIKE NAST-ANZAL.      "Number of outputs (Orig. + Cop.)
      DATA: NAST_TDARMOD LIKE NAST-TDARMOD.  "Archiving only one time
      DATA: GF_LANGUAGE LIKE SY-LANGU.
      DATA: L_FMNAME    TYPE   rs38l_fnam.
      data: CS_BIL_INVOICE  type  LBBIL_INVOICE.
      data: IS_PRINT_DATA_TO_READ type LBBIL_PRINT_DATA_TO_READ value
      'XXXXXXXXXXXXXXXXXXXXXXXX'.
      DATA: BILL_DOC_EXP    LIKE     VBCO3.
      DATA: BILL_DOC_IMP_H  LIKE     VBDKR.
      DATA: BILL_DOC_IMP_I  LIKE VBDPR OCCURS 0 WITH HEADER LINE.
      DATA: T_RC  LIKE ADRC OCCURS 0 WITH HEADER LINE.
      DATA: T_T00  LIKE T005U OCCURS 0 WITH HEADER LINE.
      DATA: L_WERKS LIKE J_1IEXCHDR-WERKS.
    DATA: I_LIKP     LIKE     LIKP OCCURS 0 WITH HEADER LINE,
         I_VBAK     LIKE     VBAK OCCURS 0 WITH HEADER LINE,
         I_LIPS     LIKE     LIPS OCCURS 0 WITH HEADER LINE,
         I_VBKD     LIKE     VBKD OCCURS 0 WITH HEADER LINE,
         I_EIKP     LIKE     EIKP OCCURS 0 WITH HEADER LINE,
         I_MARC     LIKE     MARC OCCURS 0 WITH HEADER LINE,
         I_KNA1     LIKE     KNA1 OCCURS 0 WITH HEADER LINE,
         I_T604T     LIKE     T604T OCCURS 0 WITH HEADER LINE,
         I_KONV     LIKE     KONV OCCURS 0 WITH HEADER LINE,
         I_VBRK     LIKE     VBRK OCCURS 0 WITH HEADER LINE,
          I_VBRP     LIKE     VBRP OCCURS 0 WITH HEADER LINE.
         I_T685T     LIKE     T685T OCCURS 0 WITH HEADER LINE,
         I_KONV1     LIKE     KONV OCCURS 0 WITH HEADER LINE.
    *types begin of t_vbrp.
    *include structure vbrp.
    *types grp_counter type i .
    *types end of t_vbrp.
    *data i_vbrp type standard table of t_vbrp with header line.
    *NAST-OBJKY = BILL_DOC .
      DATA : inv_code LIKE vbak-vbeln.
      BILL_DOC_EXP-SPRAS = 'E'.
      BILL_DOC_EXP-VBELN = nast-objky(10).
      inv_code = nast-objky(10).
      SELECT SINGLE WERKS INTO L_WERKS FROM J_1IEXCHDR WHERE  RDOC =
    inv_code.
    select * from vbrp into table i_vbrp where vbeln = inv_code.
    lf_formname = tnapr-sform.
    IF L_WERKS = '2000'.
        tnapr-sform = 'ZSF_SD_INVOICE'.
    ELSE.
       tnapr-sform = 'ZSD_FACTORY_EXCISE_INVOICE_PAT'.
    ENDIF.
    Read print data
      CALL FUNCTION 'LB_BIL_INV_OUTP_READ_PRTDATA'
        EXPORTING
          IF_BIL_NUMBER         = NAST-OBJKY
          IF_PARVW              = NAST-PARVW
          IF_PARNR              = NAST-PARNR
          IF_LANGUAGE           = NAST-SPRAS
          IS_PRINT_DATA_TO_READ = IS_PRINT_DATA_TO_READ
        IMPORTING
          ES_BIL_INVOICE        = CS_BIL_INVOICE
        EXCEPTIONS
          RECORDS_NOT_FOUND     = 1
          RECORDS_NOT_REQUESTED = 2
          OTHERS                = 3.
    GET THE DATA RELATED TO THE BILLING DOCUMENT BASED ON THE BILLING
    *DOCUMENT NUMBER
      CALL FUNCTION 'RV_BILLING_PRINT_VIEW'
        EXPORTING
          COMWA                              = BILL_DOC_EXP
       IMPORTING
         KOPF                               = BILL_DOC_IMP_H
        TABLES
          POS                                = BILL_DOC_IMP_I
    EXCEPTIONS
      TERMS_OF_PAYMENT_NOT_IN_T052       = 1
      OTHERS                             = 2
      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 'SSF_FUNCTION_MODULE_NAME'
        EXPORTING
          FORMNAME                 = tnapr-sform
        VARIANT                  = ' '
        DIRECT_CALL              = ' '
       IMPORTING
         FM_NAME                  = L_FMNAME
      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 L_FMNAME
        EXPORTING
      ARCHIVE_INDEX              =
      ARCHIVE_INDEX_TAB          =
      ARCHIVE_PARAMETERS         =
      CONTROL_PARAMETERS         =
      MAIL_APPL_OBJ              =
      MAIL_RECIPIENT             =
      MAIL_SENDER                =
      OUTPUT_OPTIONS             =
      USER_SETTINGS              = 'X'
      ITAB_LANDX                 =
      ITAB_ZOLLA                 =
      ITAB_AZOLL                 =
      ITAB_KZGBE                 =
      ITAB_IEVER                 =
      ITAB_LADEL                 =
      ITAB_LANDX50               =
      ITAB_VTEXT                 =
      ITAB_EXPVZ                 =
      I_KZABE                    =
      NN_LINES                   =
      S                          =
      D                          =
      I_TOTAL                    =
      I_MAKTG                    =
      I_CAL_NET                  =
          IS_BIL_INVOICE             = CS_BIL_INVOICE
          IS_KOPF                    = BILL_DOC_IMP_H
      IS_NAST                    =
      IS_REPEAT                  =
    IMPORTING
      DOCUMENT_OUTPUT_INFO       =
      JOB_OUTPUT_INFO            =
      JOB_OUTPUT_OPTIONS         =
        TABLES
       I_LIKP                     = I_LIKP
       I_VBAK                     = I_VBAK
       I_LIPS                     = I_LIPS
       I_VBKD                     = I_VBKD
       I_EIKP                     = I_EIKP
       I_MARC                     = I_MARC
       I_KNA1                     = I_KNA1
       I_T604T                    = I_T604T
       I_KONV                     = I_KONV
       I_VBRK                     = I_VBRK
         I_VBRP                     = I_VBRP
       I_T685T                    = I_T685T
       I_KONV1                    = I_KONV1
          IS_PO                      = BILL_DOC_IMP_I
    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.
    ENDFORM.                    "ENTRY
    Regards
    Santosh.

  • How to use copy of standard program for direct input in LSMW

    currently we're using object 0085 Purchase Orders and and method 0001 for standard direct input, which is processed with program RM06EEI0
    now I want to set an additional flag and avoid creating it by means of BUS PurchaseOrder.CreateFromData1 method (coz the structure is quite different and more complex).
    so my question is now how can i assign a copy of the standard program for processing?
    for better understanding I've attached a screenshot of the according screen
    [img]http://img71.imageshack.us/img71/1558/lsmwcr6.jpg[/img]

    ok, solution was to maintain table SXDA1 (SAPDXfer: Data Transfer Objects and Sub-Category).
    modify entries for DXPRG, DXPR1 and LOADPRG with custom program names

  • How to build labview global variable into dll?And how to use it in vc++ program?

    Hi!
       I want to build labview application into dll and use vc++ to call it.The labview program is a little complex,for it has many interface to vc++ and has while loop in it.When I use vc++ to call it,I must use vc++ to do other things.That is to say,vc++ creates a new thread to provide for the labview dll to run.the vc main thread goes on to other things.But the vc++ main thread must communicate with the labview dll by setting its inputs' parameters and get the results of running labview dll.Can you advise me how to realize it?
       I think global variable of labview could be useful when realizing the communication betweeb vc thread and labview dll.So I want to ask whether the labview global variable could also be built into dll and use it.Could you please tell me how to realize my idea?
       Thank you!

    [email protected] wrote:
    Hi!
    I want to build labview application into dll and use vc++ to call
    it.The labview program is a little complex,for it has many interface to
    vc++ and has while loop in it.When I use vc++ to call it,I must use
    vc++ to do other things.That is to say,vc++ creates a new thread to
    provide for the labview dll to run.the vc main thread goes on to other
    things.But the vc++ main thread must communicate with the labview dll
    by setting its inputs' parameters and get the results of running
    labview dll.Can you advise me how to realize it?
       I
    think global variable of labview could be useful when realizing the
    communication betweeb vc thread and labview dll.So I want to ask
    whether the labview global variable could also be built into dll and
    use it.Could you please tell me how to realize my idea?
       Thank you!
    You
    can't access LabVIEW globals directly from a caller to the LabVIEW DLL.
    However there is no problem in providing specific accessor VI functions
    to that global and export them as additional functions from the DLL.
    Rolf Kalbermatter
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • How to use FNDLOAD to add program to request group?

    Is there a way to use FNDLOAD to add a program to System administrators > security > responsilibity > request.
    I have try to use the following command to downlod this information to load it to other place but no record saved in ldt file:
    FNDLOAD apps/apps1234 O Y DOWNLOAD $FND_TOP/patch/115/import/afcpreqg.lct PO_RESQUEST_GROUP_2.ldt REQUEST_GROUP REQUEST_GROUP_NAME="All Reports" APPLICATION_SHORT_NAME="XXPO"
    OR
    FNDLOAD apps/apps1234 O Y DOWNLOAD $FND_TOP/patch/115/import/afcpreqg.lct PO_RESQUEST_GROUP_3.ldt REQUEST_GROUP APPLICATION_SHORT_NAME="Purchasing" REQUEST_GROUP_NAME="All Reports" UNIT_NAME="XXPO_PUR_REQ"
    if i delete APPLICATION_SHORT_NAME="Purchasing" , it downloaded many seemingly not relevant data as follow:
    Downloading REQUEST_GROUP to the data file PO_RESQUEST_GROUP_3.ldt
    Downloaded REQUEST_GROUP All Reports CUN
    Downloaded REQUEST_GROUP All Reports IGS
    Downloaded REQUEST_GROUP All Reports PSB
    Downloaded REQUEST_GROUP All Reports CSE
    Downloaded REQUEST_GROUP All Reports AHL
    Downloaded REQUEST_GROUP All Reports ENI
    Downloaded REQUEST_GROUP All Reports OFA
    Downloaded REQUEST_GROUP All Reports XTR
    Downloaded REQUEST_GROUP All Reports SQLAP
    Downloaded REQUEST_GROUP All Reports PO
    Downloaded REQUEST_GROUP All Reports CHV
    Downloaded REQUEST_GROUP All Reports QA
    Downloaded REQUEST_GROUP All Reports CE
    Downloaded REQUEST_GROUP All Reports POA
    Downloaded REQUEST_GROUP All Reports MFG
    Downloaded REQUEST_GROUP All Reports CRP
    Downloaded REQUEST_GROUP All Reports WIP
    How can I confine "Application"? which is under the field "Group" and how can I download all application named "custom puchasing" next to "Name"?

    When migrating to another instance and want to add a concurrent program to a request group, I do it in two steps. Within a shell script, I call
    1 - FNDLOAD to load ldt file (concurrent program definition)
    2 - SQLPLUS to run an sql file that call FND API that install concurrent program into proper request group.
    ex # 1 :
    FNDLOAD $apps_user/$apps_pswd@$dbsid 0 Y UPLOAD $XDO_TOP/patch/115/import/xdotmpl.lct $XX_TOP/XX_PGM.ldt - WARNING=YES CUSTOM_MODE=FORCE >> $LOG_FILE 2>&1
    ex # 2 :
    sqlplus -s $apps_user/$apps_pswd@$dbsid @$XX_TOP/XX_PGM_REQ_GROUP.sql >> $LOG_FILE 2>&1
    XX_PGM_REQ_GROUP.sql content.
    IF NOT fnd_program.program_in_group('XX_PGM','Business Online','GL Concurrent Program Group','General Ledger' ) THEN
    fnd_program.add_to_group(program_short_name => 'XX_PGM',
    program_application => 'Business Online',
    request_group => 'GL Concurrent Program Group',
    group_application => 'General Ledger');
    COMMIT;
    END IF;
    Hope this might help.

  • How to use Business Objects in program

    Hi All,
    What are Business Objects? if i want to create PurchaseOrders how can i use this Business Object in my program.i know how to create PO through Bapi's.how can i use this Business Objects ??
    Thank you,
    Madhu Rao.

    Hi Madhu,
    The below links 2 will really help
    http://help.sap.com/saphelp_46c/helpdata/en/59/ae4477488f11d189490000e829fbbd/content.htm
    http://help.sap.com/saphelp_46c/helpdata/en/59/ae4484488f11d189490000e829fbbd/frameset.htm
    Cheers!!
    VEnk@
    Edited by: Venkat Reddy on Oct 29, 2008 2:21 PM

Maybe you are looking for

  • Ipod Shuffle Problem [HELP]

    well im not sure if this is the right place, but im having trouble with itunes, when i try to copy music to my Ipod Shufle it says "The Ipod cannot be updated. The disk could not be read from or written to." but it works on my old computer =( well he

  • Easy-to-read link to App Store does not work for iOS 6?

    I have followed https://developer.apple.com/library/ios/#qa/qa1633/_index.html  to create a link that looks like http://itunes.com/apps/<applicationname> This link work for iOS 5 devices, but not on iOS 6!

  • Finding corodonates of a color.

    hi what i am trying to do is find the coridanates of anywhere there is the color red and save this in 2 variables. one  for the corodanets of the color on the x axis and one of the corordonates on the y axis. if anyone knows how please let me know an

  • How do I find out how much money I have left on an iTunes gift card that has already been activated?

    Is there a way that I can access how much money I have left on my iTunes account straight from my phone?

  • Creating PS Network header with one activity

    I need to create to a projekt the network header with one activity. so I want top proceed the following coding:      CALL FUNCTION 'BAPI_PS_INITIALIZATION'.       CALL FUNCTION 'BAPI_BUS2002_CREATE'         EXPORTING           i_network = gs_network