Recording of header text ?

Dear All,
I am recording va01 i have to pass cheque details to header text. i don't know how to do it. please help?
(taking cheque details as  text )

Recording will not work for that, Use save_text to do that after calling the BDC if you have any other requirement. If you have to do only this then use SAVE_TEXT

Similar Messages

  • How to read header text in MM contract (ME31K/ME32K) before saving record?

    Hi All,
    In ME31K / ME32K (Contracts), before saving the contract I would like to check if the user has entered header text in the contract or not.
    I am using customer exit MM06E005.
    Can anybody help me with this?
    Thanks in advance.

    Try creating dummy text id which will be part of text determination procedure @ Customers sales text & document header text.
    else, maintain the SO10-text against this text ID. whenver user createds quotation this text will be defaulted irrespective of the cusotmer.
          then based on if user want to modify the text they have to enter manually in this text id. print this text in header.
    Regards,
    Reazuddin MD

  • Header text not printed for scheduling agreement

    Hi All,
    I have issue with header text print out for scheduling agreement (SA).
    In SA when I am manually writing some note and then taking print out, system is giving me correct output with maual note.
    I have one standard text (ST) which I need to be printed in evry SA, so in SPRO I created new head text for vendor and in copying rule for text for SA, I created linkage of SA header text with Vendor head text.
    In vendor master, I inserted ST in newly created vendor header text.
    So now when ever I create new SA for vendor system will determin header text from vendor master.
    Now after creating SA when I check the SA, I am able to my ST in SA, but at the time of print out this ST in not printing.
    Please let me know what could be the reson.
    Regards,
    Sameer

    I dont understand about what you mean by expand.
    When you a print PO, PO text  (header or item) it will check to the configuration setting.
    The system didnt care if its adopted from vendor master or info record, or whatever you make in the copying rule.
    In your case : you create a standard text then it get copied into PO , then you set the standard text to the PO for print out, example the standard text : word is
    "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
    Then in the PO the text appear will be like below(the same, because it get copied)
    "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
    If you configure it in define text for SA, then it the print out it will also (the same)
    "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
    So what text need to expand?

  • Purchase Order Header Text.

    Dear all,
    We maintain the header text in PO. There are around 10 different text items in the PO header text.
    All these 10 text items are nearly same for some vendors( around say 300 vendors)  when purchases are made from these vendors.
    Please note that it is not for all vendors and not for material vendor combination (Not in Info records) but only vendor specific.
    My requirement is that is it possible to configure system so that when i create the PO for any one of  300 vendor system should automatically put/insert those header text items.
    i.e. 300 Vendors-----> Common PO Header Text
    Regards,
    SP

    Hi
    Either you can carry out the Process as specified above or.
    Create a Z table for the 10 Text Objects & maintain them.
    Create another Z table & Maintain the Vendors
    Use the Business Add-In (BAdI) ME_PROCESS_PO_CUST , which enables you to extend the business logic of the Enjoy purchase order on an individual basis.
    Use the method Process_HEADER
    Maintain the Logic of populating the Texts based on the Vendor.
    Thanks & Regards
    Kishore

  • Default header texts in purchase order

    Hi,
    I would like to ask you for help in following case.
    I need to set default purchase header text when a new PO is created in me21n.
    I found transaction VOTX where can be this done for sales order, but not for PO. Is there anything similar also in MM?
    Maybe I could use user exits in MM06E005, but I didn't find the relevant structure which keeps header texts.
    Third idea is to add header text fields into personal setting in me21n, where each user can define his own default texts but I have no idea how to do that.
    I need to set default texts which are global for all purchase orders, so it has no sense to use Info record in this case.
    Has anybody experience with this? I would appreciate any help. Thanks.

    Hi,
    you can try to solve it using BADI ME_PROCESS_PO_CUST. The method open is suitable for you problem. Here is a quote from a BADI documentation.
    The OPEN method enables you to do the following when opening a new
    document:
    o   Import new data if the document was already posted to the database
    o   Initialize your own data when creating a new document
    You get a reference for object with type IF_PURCHASE_ORDER_MM in this method. This class implements interface IF_LONGTEXTS_MM with methods like IF_LONGTEXTS_MMGET_TEXT and IF_LONGTEXTS_MMSET_TEXT. So you should be able to set long text for your new PO in this method. Check BADI documentation for more info.
    Cheers

  • URGENT HELP *** Need to load BOM Header TEXT

    Hello Experts,
    How can i load BOM Header text using LSMW
    Thanks
    S

    Two ways to upload:
    1. Via FM: SAVE_TEXT
    2. Create a recording to add text for BOM Header and Use accordingly.
    Regards
    Eswar

  • Document Header Text in BKPF

    Hello
       In BKPF the document header text is case-sentive.If we search for eg. test* then it would return all the texts starting with test(in small) and if we search for TEST* it would return the texts starting with TEST and not test also.I have a select option(Document Header Text) on the selection screen and irrespective of the case it should select all the texts which i give the search for.For e.g if I give test* then it should return texts starting with (test as well as TEST).How can this be achieved?
    Thanks.

    Hi,
    There is no simple solution to this. Either you build up a select-option yourself with all possible combinations of "test", "Test", "TEST" etc., or you would select all BKPF records in an internal table (usually not a good idea since this is normally a DB-table with many entries) and translate the BKTXT field to upper case and then select your records.
    Regards,
    John.

  • Header Text selection Option

    Hi,
      I have developed a report which include a number of fields that come from the header text of the document.  Besides, those fields are also used as the selection options.  So, I use the function module READ_TEXT to retrieve it and compare it.  The problem is the performance of the report is very bad.  It takes 3 mins to get 3 records.   Is there any way to resolve this??
    SELECT-OPTIONS: S_WADAT FOR LIKP-WADAT_IST.
      PARAMETERS: P_MAWB LIKE WA_REPORT-KZABE.
      PARAMETERS: P_HAWB LIKE LIKP-BOLNR.
      PARAMETERS: P_MATNR LIKE LIPS-MATNR.
      PARAMETERS: P_LOT(20) TYPE C.
      CLEAR: I_REPORT,I_DELIVERY,I_DELIVERY_INFO.
      REFRESH: I_REPORT,I_DELIVERY,I_DELIVERY_INFO.
      DATA WHERE_TAB(80) OCCURS 10 WITH HEADER LINE.
      DATA: BEGIN OF LTEXT OCCURS 50.
              INCLUDE STRUCTURE TLINE.
      DATA: END OF LTEXT.
      IF NOT P_HAWB IS INITIAL.
        CONCATENATE ' BOLNR = ' WHERE_TAB INTO WHERE_TAB.
        CONCATENATE WHERE_TAB '''' INTO WHERE_TAB.
        CONCATENATE WHERE_TAB P_HAWB INTO WHERE_TAB.
        CONCATENATE  WHERE_TAB '''' INTO WHERE_TAB.
        APPEND WHERE_TAB.
      ENDIF.
      IF NOT P_MATNR IS INITIAL.
        IF NOT WHERE_TAB IS INITIAL.
          CONCATENATE ' AND MATNR = ' WHERE_TAB INTO WHERE_TAB.
        ELSE.
          CONCATENATE ' MATNR = ' WHERE_TAB INTO WHERE_TAB.
        ENDIF.
        CONCATENATE WHERE_TAB '''' INTO WHERE_TAB.
        CONCATENATE WHERE_TAB P_MATNR INTO WHERE_TAB.
        CONCATENATE  WHERE_TAB '''' INTO WHERE_TAB.
        APPEND WHERE_TAB.
      ENDIF.
      SELECT A1~VBELN
             WADAT_IST
             BOLNR
             C1~LIFNR
             B1~MATNR
             LFIMG
             BTGEW
             B1~CHARG
        INTO CORRESPONDING FIELDS OF TABLE TMP_REPORT
        FROM LIKP AS A1 JOIN LIPS AS B1 ON A1~VBELN = B1~VBELN
            JOIN MCHA AS C1 ON B1~MATNR = C1~MATNR
                               AND
                               B1~WERKS = C1~WERKS
                               AND
                               B1~CHARG = C1~CHARG
         WHERE LFART = 'EL'
               AND
               WADAT_IST IN S_WADAT
               AND
               B1~CHARG NE ''
               AND
               B1~WERKS = 'ABC'
               AND
               (WHERE_TAB)
      SORT TMP_REPORT BY VBELN.
      DATA: V_FLAG TYPE I,
            V_EXCLUDE TYPE I,
            V_LOT_EXCLUDE TYPE I.
      V_FLAG = 0.
      V_EXCLUDE = 0.
      V_LOT_EXCLUDE = 0.
      IF SY-SUBRC = 0.
    * trim the parameter space
        SHIFT P_MAWB RIGHT DELETING TRAILING SPACE.
        SHIFT P_MAWB LEFT DELETING LEADING SPACE.
        SHIFT P_LOT RIGHT DELETING TRAILING SPACE.
        SHIFT P_LOT LEFT DELETING LEADING SPACE.
        LOOP AT TMP_REPORT.
          AT NEW VBELN.
            V_FLAG = 1.
            V_EXCLUDE = 0.
          ENDAT.
          IF V_FLAG = 1.
            PERFORM GET_HEADER_TEXT
                  TABLES
                       LTEXT
                  USING
                       'Z3IH'
                        TMP_REPORT-VBELN
            READ TABLE LTEXT INDEX 1.
            SPLIT LTEXT-TDLINE AT ':' INTO
            TMP_REPORT-VERUR TMP_REPORT-VERUR.
            READ TABLE LTEXT INDEX 2.
            SPLIT LTEXT-TDLINE AT ':' INTO
            TMP_REPORT-KZGBE TMP_REPORT-KZGBE.
            READ TABLE LTEXT INDEX 3.
            SPLIT LTEXT-TDLINE AT ':' INTO
            TMP_REPORT-KZABE TMP_REPORT-KZABE.
            READ TABLE LTEXT INDEX 4.
            SPLIT LTEXT-TDLINE AT ':' INTO
            TMP_REPORT-STABE TMP_REPORT-STABE.
            READ TABLE LTEXT INDEX 5.
            SPLIT LTEXT-TDLINE AT ':' INTO
            TMP_REPORT-PRONU TMP_REPORT-PRONU.
            READ TABLE LTEXT INDEX 6.
            SPLIT LTEXT-TDLINE AT ':' INTO
            TMP_REPORT-LADEL TMP_REPORT-LADEL.
            SHIFT TMP_REPORT-KZABE RIGHT DELETING TRAILING SPACE.
            SHIFT TMP_REPORT-KZABE LEFT DELETING LEADING SPACE.
            MOVE-CORRESPONDING TMP_REPORT TO WA_REPORT.
            MOVE-CORRESPONDING TMP_REPORT TO WA_TMPREPORT.
            V_FLAG = 0.
          ELSE.
            MOVE TMP_REPORT-VBELN TO WA_REPORT-VBELN.
            MOVE TMP_REPORT-LIFNR TO WA_REPORT-LIFNR.
            MOVE TMP_REPORT-MATNR TO WA_REPORT-MATNR.
            MOVE TMP_REPORT-LFIMG TO WA_REPORT-LFIMG.
          ENDIF.
          PERFORM GET_LOT_CODE USING
                                     WA_REPORT-MATNR
                                     '3LTU'
                                     WA_TMPREPORT-CHARG
                                     WA_REPORT-LOT.
          IF V_EXCLUDE <> 1 AND P_MAWB NE ''
            AND WA_TMPREPORT-KZABE NE P_MAWB .
            V_EXCLUDE = 1.
          ENDIF.
          SHIFT WA_REPORT-LOT RIGHT DELETING TRAILING SPACE.
          SHIFT WA_REPORT-LOT LEFT DELETING LEADING SPACE.
          IF P_LOT NE '' AND P_LOT NE WA_REPORT-LOT.
            V_LOT_EXCLUDE = 1.
          ELSE.
            V_LOT_EXCLUDE = 0.
          ENDIF.
          IF V_EXCLUDE <> 1 AND V_LOT_EXCLUDE <> 1.
            APPEND WA_REPORT TO I_REPORT.
            CLEAR WA_REPORT.
            CLEAR TMP_REPORT.
          ENDIF.
        ENDLOOP.
    Regards,
    Kit

    Here is my code
      FORM GET_LOT_CODE USING MATCODE PLANT BATCH LOT_CODE.
      DATA: W_OBJECTTAVLE LIKE BAPI1003_KEY-OBJECTTABLE VALUE 'MCHA',
            W_CLASSNUM LIKE BAPI1003_KEY-CLASSNUM VALUE 'Z003',
            W_CLASSTYPE LIKE BAPI1003_KEY-CLASSTYPE VALUE '022',
            IT_ALLOCVALUESNUM LIKE BAPI1003_ALLOC_VALUES_NUM OCCURS 0,
            IT_ALLOCVALUESCHAR LIKE BAPI1003_ALLOC_VALUES_CHAR OCCURS 0,
            WA_ALLOCVALUESCHAR LIKE BAPI1003_ALLOC_VALUES_CHAR,
            IT_ALLOCVALUESCURR LIKE BAPI1003_ALLOC_VALUES_CURR OCCURS 0,
            IT_RETURN LIKE BAPIRET2 OCCURS 0.
      DATA: BEGIN OF IT_OBJECT OCCURS 0.
              INCLUDE STRUCTURE BAPI1003_OBJECT_KEYS.
      DATA: END OF IT_OBJECT.
      DATA: W_OBJECT LIKE BAPI1003_KEY-OBJECT.
      CLEAR: IT_OBJECT, IT_RETURN.
      REFRESH: IT_OBJECT, IT_RETURN.
      IT_OBJECT-KEY_FIELD = 'MATNR'.
      IT_OBJECT-VALUE_INT = MATCODE.
      APPEND IT_OBJECT.
      IT_OBJECT-KEY_FIELD = 'WERKS'.
      IT_OBJECT-VALUE_INT = PLANT.
      APPEND IT_OBJECT.
      IT_OBJECT-KEY_FIELD = 'CHARG'.
      IT_OBJECT-VALUE_INT = BATCH.
      APPEND IT_OBJECT.
      CALL FUNCTION 'BAPI_OBJCL_CONCATENATEKEY'
           EXPORTING
                OBJECTTABLE    = 'MCHA'
           IMPORTING
                OBJECTKEY_CONC = W_OBJECT
           TABLES
                OBJECTKEYTABLE = IT_OBJECT
                RETURN         = IT_RETURN.
      CLEAR: IT_RETURN.
      REFRESH: IT_RETURN.
      CALL FUNCTION 'BAPI_OBJCL_GETDETAIL'
           EXPORTING
                OBJECTKEY       = W_OBJECT
                OBJECTTABLE     = W_OBJECTTAVLE
                CLASSNUM        = W_CLASSNUM
                CLASSTYPE       = W_CLASSTYPE
           TABLES
                ALLOCVALUESNUM  = IT_ALLOCVALUESNUM
                ALLOCVALUESCHAR = IT_ALLOCVALUESCHAR
                ALLOCVALUESCURR = IT_ALLOCVALUESCURR
                RETURN          = IT_RETURN.
      LOOP AT IT_ALLOCVALUESCHAR INTO WA_ALLOCVALUESCHAR.
        IF WA_ALLOCVALUESCHAR-CHARACT = 'Z_VENDOR_LOT_NUMBER'.
          LOT_CODE = WA_ALLOCVALUESCHAR-VALUE_CHAR.
        ENDIF.
      ENDLOOP.
    ENDFORM.

  • Problem for Header text of Contracts

    Hi guys,
    a suggest:I have created in customizing a new header text and I want display and manage it on header of contract but when I create the contract see always the standard header texts 'release order text', 'header text','header note' 'pricing type' 'deadlines' but my own header text number 17 there is not.
    i have simply entered in customizing Contract>Texts for Contracts>Define Text Types for Header Texts and I have created the text with sequence numeber 17...how can I display it in header of contract?
    I have seeked for in this forum but in all messages on text I don't find this problem
    Thanks in advance
    Bye

    Hi,
    am adding up...........
    Please refer the below link......
    http://www.sap-advisor.com/abap-coding/sap-text-administration-and-info-records-for-purchase-orders/
    Hope it may help you...
    Venkat.

  • Default  header text for PO

    Hello,
    Mine client requirement is like they want default header Text for all PO.Please guide me, what is the customization required?
    Regards,
    Jyoti

    Hi jyoti,
    As per my understanding of your requirement, you can try to maintain the default PO Text in the "Vendor Master Record" or in "Contract" if applicable and then you need to do the following customisation to adopt these texts in the Purchase Orders.
    IMG -> Material Management -> Purchasing -> Purchase Order -> Texts for Purchase Orders -> Define Text Types for Header Texts and Define Copying Rules for Header Texts.
    In Define Copuying Rules for Header Texts -tab you can maintain that in which Target Header Text, the deault PO text should be adopted and from where i.e. From Vendor Master Record or Contract or RFQ. Check which of this satisfy your requiremnt to the maximum extent.
    Please check this and see if your requirement is fulfilled or not.
    Regards,
    Ankit
    Edited by: Ankit Patodi on Jan 12, 2011 11:55 AM

  • Delivery Header Text in SAP Query SQ01

    Hi Friends,
    My requirement is that I need to display the Header Text contents in Outbound delivery in a Query report using SQ01.
    As far as I know, we can pull only table fields in SQ01.
    Is it possible to include Text contents in SAP Query? Can we develop or enhance it?
    Regards,
    AK

    You can add structure and code in a dataset using SQ02, then it will be available to use in SQ01, but a long text can consist of many lines, and so you may require to truncate the text - read [SAP Query|http://help.sap.com/saphelp_NW70EHP1core/helpdata/en/d2/cb3efb455611d189710000e8322d00/frameset.htm] documentation
    - [Creating Additional Structures|http://help.sap.com/saphelp_NW70EHP1core/helpdata/en/d9/9958d4c50a11d396f80000e82de14a/frameset.htm]
    - [Further Code|http://help.sap.com/saphelp_NW70EHP1core/helpdata/en/d2/cb4504455611d189710000e8322d00/frameset.htm] (I suggest record processing or after the query get the table with the text id)
    So create a structure with some text fields, and fill it for every record read in futher code part.
    Regards,
    Raymond

  • Reg sales order Header text VA01/VA02

    Hi,
    In VA01/VA02 ..
    From menu bar
    Goto   -> Header  ->  Texts
    In this texts tabstrip left side Form header, Header note1, Header note2 & Geo transmit status
    These 4 elements are there.
    Now the above 4 elements r working if u r double clicking on them, then u can enter the text.
    but my requirement is that should work even if u press single click also...
    How to achieve it..
    Thanks in advance..
    VR

    Hi venkat,
        can you please address my problem, as u got same problem like me... below is the details ...
    I am facing some problem during the recording of hader text.. Details given below...
    I need to do this by using BDC...
    &#61607; VA01 Steps as follows:
    1. Open VA01
    o Enter G2 or L2 order Type
    o Enter 9991 for Sales Org
    o Enter 01 for Dist Channel
    o Enter 99 for Division
    2. Enter Customer SAP # from spreadsheet to ship to and sold to
    (Enter some appropriate number)
    3. Enter Material Code from spreadsheet to Material
    (Enter some appropriate number)
    4. Enter target quantity as 1
    5. Enter Billing date as system date
    6. Go to Sales Tab
    7. Select Blank for billing block
    8. Enter order reason 013 for G2 type or 012 for L2
    9. Goto Header, Texts, Choose Invoice header text
    10. Enter SVB# from file as well as Quarter Text from file in notes
    11. Save
    this is want i need to do in order to create invoice serivce request by using BDC.
    I can able to get the fields till 8 th point ( i can able to write the program ), but from the 9 th point i m facing the problem..
    Bcz it just i need to enter some text here..( may be it's bcz of click )
    This is could not able to do it , can you please help me how can i do this ?
    Please let me know if i m not clear with my explanation...
    Looking forward for your response...
    Regards,
    Suresh...

  • Direct navigation of header text of vd53 from alv

    Hi expert
    I have created one alv report based on the delivery level.The user need to know the hader text information of VD53.I alredy developed click event in the report.The problem is user need so many navigation reach the header text.The user want to navigate directly to the header text.
    Please give any soln for this
    Regards
    Manoj

    Hi Manoj,
    U have to make a BDC recording VD53 upto that particular screen. now in the click event make a call transaction for the BDC recording in Error mode.
    This will help user to navigate to the particular screen without interacting.
    Amitava

  • User exit---to capture SO header text

    Hi all,
    Requirement is to maintain SO header texts (va02>goto>header-->texts) in a z table (i.e, acceptance numbers..like remark1, remark2,3  and 4).
    plz guide me from which structure we can capture this value..i mean runtime structure..
    I can use user-exit..MV45AFZZ--->userexit_delete_document
    or any otherwayz..?

    Hi Tuborg,
    Use Function module READ_TEXT.
    or u can follow the program.
    I think it will help u to fulfill ur requirement.
    *& Report  ZSO_TEXT_CHANGE
    REPORT  zso_text_change.
    TABLES : vbak,
             vbap,
             cfstructur.
    DATA : BEGIN OF itab OCCURS 0,
           vbeln LIKE vbak-vbeln,
           posnr LIKE vbap-posnr,
           text1(30),
           text2(30),
           text3(20),
           END OF itab.
    DATA : name LIKE stxh-tdname,
           l_tid LIKE stxh-tdid,
           obj LIKE stxh-tdid.
    *& CUSTOM CONTROL DATA DECLARATIONS
    DATA: init,
          container1 TYPE REF TO cl_gui_custom_container,
          container2 TYPE REF TO cl_gui_custom_container,
          container3 TYPE REF TO cl_gui_custom_container,
          editor1    TYPE REF TO cl_gui_textedit,
          editor2    TYPE REF TO cl_gui_textedit,
          editor3    TYPE REF TO cl_gui_textedit.
    DATA: event_tab TYPE cntl_simple_events,
          event     TYPE cntl_simple_event.
    data declarations for save long text
    TYPES: BEGIN OF type_text ,
           line(65),
    END OF type_text.
    DATA:text_tab1 TYPE STANDARD TABLE OF type_text,
         text_tab2 TYPE STANDARD TABLE OF type_text,
         text_tab3 TYPE STANDARD TABLE OF type_text,
         texttab1 LIKE LINE OF text_tab1,
         texttab2 LIKE LINE OF text_tab1,
         texttab3 LIKE LINE OF text_tab1,
                line(256) TYPE c,
                field LIKE line,
                lsel LIKE sy-lisel,
                lsel1 LIKE sy-lisel,
                lin LIKE sy-lilli,
                val(50),
                val_c(50),
                val_scr(50),
                scr_val(50),
                val1(6),
                l_posnr LIKE vbap-posnr,
                l_posnr1 LIKE vbap-posnr,
                l_text1(30),
                l_vbeln LIKE vbap-vbeln.
    DATA: textlines LIKE tline-tdline OCCURS 0.
    DATA: ls_thead LIKE thead.
    DATA: lt_tline1 LIKE TABLE OF tline WITH HEADER LINE,
          lt_tline2 LIKE TABLE OF tline WITH HEADER LINE,
          lt_tline3 LIKE TABLE OF tline WITH HEADER LINE.
    DATA BEGIN OF header OCCURS 10.
            INCLUDE STRUCTURE thead.
    DATA END OF header.
    DATA: gcontrol  LIKE cfcontrol,
            l_subrc LIKE sy-subrc.
    DATA: BEGIN OF pc_tab OCCURS 10,
            line LIKE tline-tdline,
          END OF pc_tab.
    DATA: BEGIN OF pc_tab1 OCCURS 10,
            line LIKE tline-tdline,
          END OF pc_tab1.
    DATA: long_file(23) TYPE c.
    PARAMETERS : vbeln LIKE vbak-vbeln OBLIGATORY.
    SELECT-OPTIONS : posnr FOR vbap-posnr.
    INITIALIZATION.
      CLEAR : pc_tab.
      REFRESH pc_tab.
    START-OF-SELECTION.
      SELECT vbeln posnr
      FROM vbap
      INTO TABLE itab
      WHERE vbeln = vbeln
      AND   posnr IN posnr.
    LOOP AT itab.
       itab-text1 = 'Material sales text'.
       itab-text2 = 'Technical Specifications'.
       itab-text3 = 'Packing Note'.
       MODIFY itab TRANSPORTING text1 text2 text3.
    ENDLOOP.
    END-OF-SELECTION.
      WRITE: /5 'Header Level Text' COLOR 5.
      SKIP 3.
      WRITE:  /5 'General Remarks in Amendment',
              /5 'General Specifications',
              /5 'Instructions to Accounts ',
              /5 'Instructions to Product Engg',
              /5 'Instructions to Electrical ',
              /5 'Instructions to Service  ',
              /5 'Instructions to Despatch ',
              /5 'Instructions to Works ',
              /5 'Instructions to MMD      ',
              /5 'Instructions to OED ',
              /5 'Instructions to Project Markt',
              /5 'Painting Details ',
              /5 'Docs. Reqd. for Insp. Call ',
              /5 'Docs. to be sent with Invoice ',
              /5 'Spl action plan for SO Exec',
              /5 'Spl. Inst. for record keeping ',
              /5 'Customer Comm. Address ',
              /5 'Customer Supplied Products ',
              /5 'Cust. prods/traceability reqts ',
              /5 'Qualification Tests ',
              /5 'Instrument Calib. data to Cust ',
              /5 'Test Cert. reqd. for submisn ',
              /5 'Customer Inspection Stages  ',
              /5 'Un resolved points  ',
              /5 'Regret Reason ',
              /5 'Terms of payment ',
              /5 'Additional Commercial Terms ',
              /5 'Escalation',
              /5 'Mode of Despatch Details ',
              /5 'Packing Details ',
              /5 'QAP Details ',
              /5 'Approved Transporters ',
              /5 'Eye Catch ',
              /5 'LOI Details ',
              /5 'Delivery Details ',
              /5 'Order Description ',
              /5 'Penalty / LD Clause ',
              /5 'Activity Completion Schedule ',
              /5 'Inspection Details',
              /5 'Checked By ',
              /5 'Authorised By',
              /5 'Distribution',
              /5 'Send Original&Dupl. Inv. to',
              /5 'Send Copies of Inv.&Challan to ',
              /5 'Send R/R & L/R to',
              /5 'Bankers Name & Address',
              /5 'Sales Tax Details',
              /5 'Excise Duty Details',
              /5 'CST Number & Date',
              /5 'SST Number & Date',
              /5 'Bank Charges Details',
              /5 'Price Basis Details',
              /5 'Freight Details',
              /5 'Customer Collection Details',
              /5 'Road Permit Details',
              /5 'Insurance Details'.
      SKIP 5.
      WRITE: /25 'Item Level Text' COLOR 5.
      ULINE AT /24(20).
      SKIP 3.
      LOOP AT itab.
        WRITE: /5 itab-posnr.
        l_text1 = 'Technical Specifications'.
        WRITE  : 20 l_text1.
        CLEAR l_text1.
        l_text1 = 'Material sales text'.
        WRITE  : 50 l_text1.
        CLEAR l_text1.
        l_text1 = 'Packing Note'.
        WRITE  : 80 l_text1.
        HIDE : l_text1.
      ENDLOOP.
      CLEAR itab.
    AT LINE-SELECTION.
      CLEAR : lsel, lsel1.
      REFRESH text_tab2.
      lsel = sy-lisel.
      SHIFT lsel LEFT DELETING LEADING space.
      l_posnr = lsel+0(6).
      val1 = l_posnr.
    lin = sy-lilli.
    READ LINE lin FIELD VALUE itab-text1 .
      GET CURSOR FIELD l_text1 VALUE val.
      val_c = val.
      IF l_posnr IS NOT INITIAL.
        IF val = val1.
          MESSAGE s398(00) WITH 'Select a Item text'.
        ELSE.
          PERFORM itab_text.
          CALL SCREEN 0100.
        ENDIF.
      ELSEIF l_posnr IS INITIAL.
        PERFORM read_text.
        CALL SCREEN 0100.
      ENDIF.
    *&      Module  STATUS_0100  OUTPUT
          text
    MODULE status_0100 OUTPUT.
      SET PF-STATUS 'ZMENU'.
    SET TITLEBAR 'xxx'.
      IF l_posnr IS NOT INITIAL.
        CLEAR val_scr.
        CONCATENATE l_posnr '-' val INTO val_scr SEPARATED BY space.
        scr_val = val_scr.
      ELSE.
        scr_val = val.
      ENDIF.
      CLEAR :val_scr,l_posnr,val.
      INITIALIZING TEXT EDIT CUSTOM CONTROL
      IF init IS INITIAL.
        init = 'X'.
        CREATE OBJECT: container1 EXPORTING container_name = 'CUSTOM1',
                       editor1    EXPORTING parent = container1
    WORDWRAP SET SO THAT TEXT DOES NOT EXCEED THE INTERNAL TABLE FIELD
    *LENGTH.
    wordwrap_mode = cl_gui_textedit=>wordwrap_at_fixed_position
    wordwrap_mode = cl_gui_textedit=>wordwrap_at_windowborder
    wordwrap_position = '60'
    wordwrap_to_linebreak_mode = cl_gui_textedit=>true,
                       container2 EXPORTING container_name = 'CUSTOM2',
                       editor2    EXPORTING parent = container2
    wordwrap_mode = cl_gui_textedit=>wordwrap_at_fixed_position
    wordwrap_mode = cl_gui_textedit=>wordwrap_at_windowborder
    wordwrap_position = '60'
    wordwrap_to_linebreak_mode = cl_gui_textedit=>true.
        CALL METHOD editor1->set_text_as_r3table
          EXPORTING
            table = text_tab1.
        CALL METHOD editor2->set_text_as_r3table
          EXPORTING
            table = text_tab2.
        CALL METHOD editor1->delete_text.
        CALL METHOD editor2->delete_text.
    ELSE.
       CALL METHOD editor2->delete_text.
      ENDIF.
      CALL METHOD editor1->set_text_as_r3table
        EXPORTING
          table = text_tab1.
      CALL METHOD editor2->set_text_as_r3table
        EXPORTING
          table = text_tab2.
    ENDMODULE.                 " STATUS_0100  OUTPUT
    *&      Module  USER_COMMAND_0100  INPUT
          text
    MODULE user_command_0100 INPUT.
      CASE sy-ucomm.
        WHEN 'DOWNLOAD'.
          PERFORM header1.
          PERFORM header.
          PERFORM download ."changing COM_FILE LIKE LONG_FILE.
       WHEN 'SAVE'.
         PERFORM header1.
         PERFORM header.
        WHEN 'BACK' OR 'EXIT' OR 'CANCEL'.
          SET SCREEN 0.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND_0100  INPUT
    *&      Form  read_text1
          text
    -->  p1        text
    <--  p2        text
    FORM read_text1 USING   p_l_tid.
      CLEAR : lt_tline1.
      REFRESH text_tab1.
      l_tid = p_l_tid.
      name = vbeln.
      CALL FUNCTION 'READ_TEXT'
        EXPORTING
      CLIENT                        = SY-MANDT
          id                            = p_l_tid
          language                      = 'E'
          name                          = name
          object                        = 'VBBK'
      ARCHIVE_HANDLE                = 0
      LOCAL_CAT                     = ' '
    IMPORTING
      HEADER                        =
        TABLES
          lines                         =  lt_tline1
    EXCEPTIONS
       id                            = 1
       language                      = 2
       name                          = 3
       not_found                     = 4
       object                        = 5
       reference_check               = 6
       wrong_access_to_archive       = 7
       OTHERS                        = 8
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        EXIT.
      ENDIF.
      LOOP AT lt_tline1 .
       move-corresponding lt_tline1 to TEXT_tab1.
        APPEND lt_tline1-tdline TO text_tab1 .
       move '/' to lt_tline3-tdformat.
      ENDLOOP.
      REFRESH text_tab2.
    ENDFORM.                    " read_text1
    *&      Form  read_text
          text
    -->  p1        text
    <--  p2        text
    FORM read_text .
      CASE lsel.
        WHEN 'General Remarks in Amendment'.
          PERFORM read_text1 USING 'Z070'.
        WHEN 'General Specifications'.
          PERFORM read_text1 USING 'Z001'.
        WHEN 'Instructions to Accounts'.
          PERFORM read_text1 USING 'Z002'.
        WHEN 'Instructions to Product Engg'.
          PERFORM read_text1 USING 'Z003'.
        WHEN 'Instructions to Electrical'.
          PERFORM read_text1 USING 'Z004'.
        WHEN 'Instructions to Service'.
          PERFORM read_text1 USING 'Z005'.
        WHEN 'Instructions to Despatch'.
          PERFORM read_text1 USING 'Z006'.
        WHEN 'Instructions to Works'.
          PERFORM read_text1 USING 'Z007'.
        WHEN 'Instructions to MMD'.
          PERFORM read_text1 USING 'Z008'.
        WHEN 'Instructions to OED'.
          PERFORM read_text1 USING 'Z009'.
        WHEN 'Instructions to Project Markt'.
          PERFORM read_text1 USING 'Z037'.
        WHEN 'Painting Details'.
          PERFORM read_text1 USING 'Z010'.
        WHEN 'Docs. Reqd. for Insp. Call'.
          PERFORM read_text1 USING 'Z011'.
        WHEN 'Docs. to be sent with Invoice'.
          PERFORM read_text1 USING 'Z012'.
        WHEN 'Spl action plan for SO Exec'.
          PERFORM read_text1 USING 'Z013'.
        WHEN 'Spl. Inst. for record keeping'.
          PERFORM read_text1 USING 'Z014'.
        WHEN 'Customer Comm. Address'.
          PERFORM read_text1 USING 'Z015'.
        WHEN 'Customer Supplied Products'.
          PERFORM read_text1 USING 'Z016'.
        WHEN 'Cust. prods/traceability reqts'.
          PERFORM read_text1 USING 'Z017'.
        WHEN 'Qualification Tests'.
          PERFORM read_text1 USING 'Z018'.
        WHEN 'Instrument Calib. data to Cust'.
          PERFORM read_text1 USING 'Z019'.
        WHEN 'Test Cert. reqd. for submisn '.
          PERFORM read_text1 USING 'Z020'.
        WHEN 'Customer Inspection Stages '.
          PERFORM read_text1 USING 'Z021'.
        WHEN 'Un resolved points '.
          PERFORM read_text1 USING 'Z022'.
        WHEN 'Regret Reason '.
          PERFORM read_text1 USING 'Z023'.
        WHEN 'Terms of payment '.
          PERFORM read_text1 USING 'Z120'.
        WHEN 'Previous Sales Order '.
          PERFORM read_text1 USING 'Z040'.
        WHEN 'Escalation'.
          PERFORM read_text1 USING 'Z041'.
        WHEN 'Mode of Despatch Details '.
          PERFORM read_text1 USING 'Z042'.
        WHEN 'Packing Details '.
          PERFORM read_text1 USING 'Z043'.
        WHEN 'QAP Details '.
          PERFORM read_text1 USING 'Z044'.
        WHEN 'Approved Transporters  '.
          PERFORM read_text1 USING 'Z045'.
        WHEN 'Eye Catch  '.
          PERFORM read_text1 USING 'Z046'.
        WHEN 'LOI Details  '.
          PERFORM read_text1 USING 'Z047'.
        WHEN 'Delivery Details  '.
          PERFORM read_text1 USING 'Z048'.
        WHEN 'Order Description  '.
          PERFORM read_text1 USING 'Z049'.
        WHEN 'Penalty / LD Clause '.
          PERFORM read_text1 USING 'Z050'.
        WHEN 'Activity Completion Schedule  '.
          PERFORM read_text1 USING 'Z051'.
        WHEN 'Inspection Details '.
          PERFORM read_text1 USING 'Z052'.
        WHEN 'Checked By '.
          PERFORM read_text1 USING 'Z053'.
        WHEN 'Authorised By  '.
          PERFORM read_text1 USING 'Z054'.
        WHEN 'Distribution '.
          PERFORM read_text1 USING 'Z055'.
        WHEN 'Send Original&Dupl. Inv. to  '.
          PERFORM read_text1 USING 'Z056'.
        WHEN 'Send Copies of Inv.&Challan to '.
          PERFORM read_text1 USING 'Z057'.
        WHEN 'Send R/R & L/R to  '.
          PERFORM read_text1 USING 'Z058'.
        WHEN 'Bankers Name & Address  '.
          PERFORM read_text1 USING 'Z059'.
        WHEN 'Sales Tax Details  '.
          PERFORM read_text1 USING 'Z060'.
        WHEN 'Excise Duty Details  '.
          PERFORM read_text1 USING 'Z061'.
        WHEN 'CST Number & Date  '.
          PERFORM read_text1 USING 'Z062'.
        WHEN 'SST Number & Date  '.
          PERFORM read_text1 USING 'Z063'.
        WHEN 'Bank Charges Details '.
          PERFORM read_text1 USING 'Z064'.
        WHEN 'Price Basis Details '.
          PERFORM read_text1 USING 'Z065'.
        WHEN 'Freight Details  '.
          PERFORM read_text1 USING 'Z066'.
        WHEN 'Customer Collection Details  '.
          PERFORM read_text1 USING 'Z067'.
        WHEN 'Road Permit Details  '.
          PERFORM read_text1 USING 'Z068'.
        WHEN 'Insurance Details '.
          PERFORM read_text1 USING 'Z069'.
      ENDCASE.
    ENDFORM.                    " read_text
    *&      Form  itab_text
          text
    -->  p1        text
    <--  p2        text
    FORM itab_text .
    LOOP AT itab WHERE posnr = posnr.
       IF itab-posnr = lsel.
       CASE lsel.
         WHEN lsel.
      READ TABLE itab WITH KEY posnr = l_posnr.
      lsel1 = l_posnr.
      l_posnr1 = l_posnr.
      SHIFT lsel1 LEFT DELETING LEADING space.
      CONCATENATE itab-vbeln lsel1 INTO lsel1.
      CASE val.
        WHEN 'Material sales text'.
          PERFORM read_text2 USING '0001'.
        WHEN 'Technical Specifications'.
          PERFORM read_text2 USING 'Z001'.
        WHEN 'Packing Note'.
          PERFORM read_text2 USING 'Z005'.
      ENDCASE.
       ENDIF.
    ENDLOOP.
    ENDFORM.                    " itab_text
    *&      Form  read_text2
          text
         -->P_LSEL  text
    FORM read_text2 USING  p_lsel.
      CLEAR : lt_tline1.
      REFRESH text_tab1.
      CLEAR name.
      CLEAR obj.
    DATA : name LIKE stxh-tdname.
      name = lsel1.
      obj = p_lsel.
      CALL FUNCTION 'READ_TEXT'
        EXPORTING
      CLIENT                        = SY-MANDT
          id                            = p_lsel
          language                      = 'E'
          name                          = name
          object                        = 'VBBP'
      ARCHIVE_HANDLE                = 0
      LOCAL_CAT                     = ' '
    IMPORTING
      HEADER                        =
        TABLES
          lines                         =  lt_tline1
    EXCEPTIONS
       id                            = 1
       language                      = 2
       name                          = 3
       not_found                     = 4
       object                        = 5
       reference_check               = 6
       wrong_access_to_archive       = 7
       OTHERS                        = 8
      IF sy-subrc <> 0.
        CLEAR lsel1.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        EXIT.
      ENDIF.
      LOOP AT lt_tline1 .
       move-corresponding lt_tline1 to TEXT_tab1.
        APPEND lt_tline1-tdline TO text_tab1 .
       move '/' to lt_tline3-tdformat.
      ENDLOOP.
    ENDFORM.                    " read_text2
    *&      Form  save_text
          text
    -->  p1        text
    <--  p2        text
    FORM save_text1 ."USING p_l_tid.
      CALL METHOD editor2->get_text_as_r3table
        IMPORTING
          table = text_tab2.
      CLEAR lt_tline2.
      REFRESH lt_tline2.
      MOVE '*' TO lt_tline2-tdformat.
      LOOP AT text_tab2 INTO texttab2.
        MOVE texttab2 TO lt_tline2-tdline.
        APPEND lt_tline2.
        MOVE '/' TO lt_tline2-tdformat.
      ENDLOOP.
    HEADER-TDOBJECT = 'VBBK'.
    HEADER-TDNAME = p_l_tid.
    HEADER-TDID = 'ZTC1'.
    HEADER-TDSPRAS = 'EN'.
      CALL FUNCTION 'SAVE_TEXT'
        EXPORTING
      CLIENT                = SY-MANDT
          header                = header
      INSERT                = ' '
       savemode_direct       = 'X'
      OWNER_SPECIFIED       = ' '
      LOCAL_CAT             = ' '
    IMPORTING
      FUNCTION              =
       newheader             = ls_thead
    TABLES
          lines                 = lt_tline2.
    EXCEPTIONS
      ID                    = 1
      LANGUAGE              = 2
      NAME                  = 3
      OBJECT                = 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.
    ELSEIF sy-subrc  = 0.
       MESSAGE i398(00) WITH 'Text Saved'.
      ENDIF.
    ENDFORM.                    " save_text1
    *&      Form  header
          text
    -->  p1        text
    <--  p2        text
    FORM header .
      PERFORM save_text1 .
    ENDFORM.                    " header
    *&      Form  header1
          text
    -->  p1        text
    <--  p2        text
    FORM header1 .
      IF lsel1 IS NOT INITIAL.
        CLEAR header.
        REFRESH header.
        header-tdobject = 'VBBP'.
        header-tdname   = name.
        header-tdid     = obj.
        header-tdspras  = 'EN'.
        APPEND header.
      ELSEIF lsel1 IS INITIAL.
        CLEAR header.
        REFRESH header.
        header-tdobject = 'VBBK'.
        header-tdname = vbeln.
        header-tdid = l_tid.
        header-tdspras = 'EN'.
        APPEND header.
      ENDIF.
    ENDFORM.                                                    " header1
    *&      Form  download
          text
    -->  p1        text
    <--  p2        text
    FORM download ."CHANGING .
    DATA : dcp_file   LIKE long_file.
      DATA fullpath TYPE string.
      l_vbeln = vbeln.
      SHIFT l_vbeln LEFT DELETING LEADING '0'.
    concatenate 'C:\' l_vbeln '.txt' into   gcontrol-directory.
      CONCATENATE 'C:\' l_vbeln '.doc' INTO   fullpath.
    gcontrol-directory
      = 'C:\Text.txt'.
      = 'C:\Documents and Settings\Subhasis Mukherjee\Desktop\Text.txt'.
      CLEAR pc_tab.
      REFRESH pc_tab.
      IF l_posnr1 IS NOT INITIAL.
        CONCATENATE l_posnr1 '-' val_c INTO val_c SEPARATED BY space.
      ENDIF.
      pc_tab = val_c.
      APPEND pc_tab.
      pc_tab = 'Previous Text'.
      APPEND pc_tab.
         DO 2 TIMES.
      pc_tab = ''.
      APPEND pc_tab.
         ENDDO.
      LOOP AT text_tab1 INTO texttab1.
       IF sy-tabix = 1.
         IF l_posnr IS NOT INITIAL.
           CONCATENATE l_posnr '-' val INTO val SEPARATED BY space.
         ENDIF.
         pc_tab = val.
         APPEND pc_tab.
         pc_tab = 'Previous Text'.
         APPEND pc_tab.
         DO 2 TIMES.
         pc_tab = ''.
         APPEND pc_tab.
         ENDDO.
       ENDIF.
        pc_tab = texttab1-line.
        APPEND pc_tab.
       AT LAST.
         pc_tab = '***************************'.
         APPEND pc_tab.
       ENDAT.
      ENDLOOP.
      LOOP AT text_tab2 INTO texttab2.
        CLEAR pc_tab.
        IF sy-tabix = 1.
          DO 3 TIMES.
            pc_tab = ''.
            APPEND pc_tab.
          ENDDO.
          pc_tab = 'Changed Text'.
          APPEND pc_tab.
           DO 2 TIMES.
          pc_tab = ''.
          APPEND pc_tab.
           ENDDO.
        ENDIF.
        pc_tab = texttab2-line.
        APPEND pc_tab.
        AT LAST.
          pc_tab = '- - - - - - - - - - - - - - - - - - - - - - - - - - - '.
          APPEND pc_tab.
        ENDAT.
      ENDLOOP.
         CALL FUNCTION 'GUI_FILE_SAVE_DIALOG'
         EXPORTING
           window_title      = 'Path'
           default_extension = 'C:\'
           default_file_name = 'TEST.XLS'
         IMPORTING
           fullpath          = fullpath.
      CALL FUNCTION 'GUI_DOWNLOAD'
        EXPORTING
          filename                = fullpath
          filetype                = 'ASC'
          append                  = 'X'
        TABLES
          data_tab                = pc_tab
        EXCEPTIONS
          file_write_error        = 1
          no_batch                = 2
          gui_refuse_filetransfer = 3
          invalid_type            = 4
          no_authority            = 5
          unknown_error           = 6
          header_not_allowed      = 7
          separator_not_allowed   = 8
          filesize_not_allowed    = 9
          header_too_long         = 10
          dp_error_create         = 11
          dp_error_send           = 12
          dp_error_write          = 13
          unknown_dp_error        = 14
          access_denied           = 15
          dp_out_of_memory        = 16
          disk_full               = 17
          dp_timeout              = 18
          file_not_found          = 19
          dataprovider_exception  = 20
          control_flush_error     = 21
          OTHERS                  = 22.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ELSE.
        MESSAGE s001(00) WITH 'File downloaded successfully'.
      ENDIF.
    ENDFORM.                    " download
    Reward points pls if it is helpfull
    Regards
    Srimanta

  • BDC to change header Text

    hello friends,
    need ur help.
    I have made recording for changing header text
    cForm name & cForm Ammout
    but the fields are not recorded in recording.
    is their any issue of sap script?
    i get code from recording as follows.
    perform open_group.
    perform bdc_dynpro      using 'SAPMV60A' '0101'.
    perform bdc_field       using 'BDC_CURSOR'
                                  'VBRK-VBELN'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '/00'.
    perform bdc_field       using 'VBRK-VBELN'
                                  '3100000384'.
    perform bdc_dynpro      using 'SAPMV60A' '0104'.
    perform bdc_field       using 'BDC_CURSOR'
                                  'VBRK-FKART'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '=KFTE'.
    perform bdc_dynpro      using 'SAPMV60A' '6001'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '=%_GC 123 22'.
    perform bdc_dynpro      using 'SAPMV60A' '6001'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '=%_GC 123 22'.
    perform bdc_dynpro      using 'SAPMV60A' '6001'.
    perform bdc_field       using 'BDC_OKCODE'
                                  '=SICH'.
    perform bdc_transaction using 'VF02'.
    perform close_group.
    please help me.
    suggest answer.

    To update text use the FM  'SAVE_TEXT'.

Maybe you are looking for