Table Event - SM30 - Entering into transaction

Hi All,
Before posting this message I looked for a solution in the forum, but from the messages I found none of them has what I need.
I would like to know which event code I have to use to update a field in a table in SM30 when entering it.
Thanks in advance!
Robson

Seshu,
Thank you for your reply, but doesn't work.
I have a table with 2 fields: Code and Description.
I need when entering in transaction, before display data on screen, an event update Description based on Code. The event 01 is not called at this moment. I've found events 19 and 25, but inside them, data still not charged in table.
Thanks,
Robson

Similar Messages

  • How do you date and time stamp iCal entries?  We share an event calendar and need to know when a new event was entered into iCal.

    How do you date and time stamp iCal entries?  We share an event calendar and need to know when a new event was entered into iCal.

    BKBK,
    Thank you for your response. That does adequately cover the
    client-originated sessions, but still leaves the ability I am
    looking for unavailable.
    It did serve to definitively answer my most pressing
    question, however, with this statement:
    Note: ColdFusion cannot create a session if an initiator
    application uses a SendGatewayMessage method to start an
    interaction with a client, such as an SMS user. In this case, the
    sending code must keep track (for example, in a database) of the
    messages it sends and their destinations. When a response event
    arrives, it can look up the origniatorID to determine whether it
    was in response to an outgoing message.
    I will play around with the Application scope to see if there
    might be a workable solution there.
    RLS

  • IPhone 4 lost all events entered into iPhone during sync

    I have a new iPhone 4. I just setup my iPhone to sync with my calendar in Outlook. I had entered 5 events into the iPhone and none of them were in my Outlook calendar after sync and they had been wiped out on my iPhone. The events I entered into my Outlook DID show up on my iPhone. Strange. Am I missing something? This is NOT an Exchange account.

    Hi,
    A few days ago my iP4 locked up. I did a hard reboot ("home" and "power" buttons). When the phone came back, all of my contacts had gone; however, it them re-synched over WiFi so I have all the details back on my phone... BUT... all of the contact photos have been messed around, so now I have the wrong faces on all of my iP4 contacts (but they are correct on my win7 laptop which I sync from).
    Anybody else seen this?
    If so, any resolutions to re-sync?
    ./ukaawe

  • How to populate date & time when user enter data for custom table in sm30

    Can anyone tell me How to populate system date & time when user enter data for custom table in sm30..
      Req is
      i have custom table and using sm30 user can enter data.
    after saving date i want to update date & time in table
    Pls let me know where to write the code?
    Thanks in Advance

    You have to write the code in EVENT 01 in SE54 transaction. Go to SE54, enter your Ztable name and in the menu 'Environment-->Events'. Press 'ENTER' to go past the popup message. In the next screen, click on 'New Entries'. In the first column, enter 01 and in the next column give some name for your routine(say UPDATE_USER_DATE_TIME). Then click on the souce code icon that appears in blue at the end of the row. In the code, you need logic like below.
    FORM update_user_date_time.
      DATA: f_index LIKE sy-tabix.
      DATA: BEGIN OF l_total.
              INCLUDE STRUCTURE zztable.
      INCLUDE  STRUCTURE vimtbflags.
      DATA  END OF l_total.
      DATA: s_record TYPE zztable.
      LOOP AT total INTO l_total.
        IF l_total-vim_action = aendern OR
           l_total-vim_action = neuer_eintrag.
          MOVE-CORRESPONDING l_total TO s_record.
          s_record-zz_user = sy-uname.
          s_record-zz_date = sy-datum.
          s_record-zz_time = sy-uzeit.
          READ TABLE extract WITH KEY l_total.
          IF sy-subrc EQ 0.
            f_index = sy-tabix.
          ELSE.
            CLEAR f_index.
          ENDIF.
          MOVE-CORRESPONDING s_record TO l_total.
          MODIFY total FROM l_total.
          CHECK f_index GT 0.
          MODIFY extract INDEX f_index FROM l_total.
        ENDIF.
      ENDLOOP.
    ENDFORM.                    " UPDATE_USER_DATE_TIME
    Here ZZTABLE is the Z table and ZZ_USER, ZZ_DATE, and ZZ_TIME are the fields that are updated.

  • Query a view w/data entered into a text field populated by 2 table fields

    Hello, Looking for advise!!! I have a tabular canvas thats datablock uses a view to populate. In this canvas I have a text field that has been populated with first_name || ' ' || last_name in the database node of the property pallate column name. The text field is not in the table or view. I have created it in the data block and make it a database item. However, I would like to have the user push a search button to go into ENTER_QUERY mode then the user would enter the criteria to search on in this text field. The user would then push button to EXECUTE_QUERY. The result is I retrieve all records. I want any search criteria entered into this field to be used against the last_name field to retrieve any records equal to the search criteria entered, for example A%. Does anyone know if this is possible?

    Hi!
    You have to use PRE-QUERY trigger to compose the search criteria. Below I put an example of it. You have to have at least one item in the block wich is true database item (e.g. it has to exist in table or view on which your block is based). In the following example EMP_DESC is your non-database search item and EMP_ID is the database one.
    Declare
    Dummy VARCHAR2 (2000);
    begin
    if :EMP.EMP_DESC IS NOT NULL and :EMP.EMP_ID IS NULL
    then
    Dummy := '#IN (SELECT emp_id FROM Employees WHERE Upper (emp_first_name)||'' ''||Upper (emp_sec_name) LIKE Upper (''%'||:EMP.EMP_DESC||'%''))';
    Copy (Dummy, 'EMP.EMP_ID');
    end if;
    end;
    Thats it. Note the # sign in the first position of the Dummy assignment. This is required by forms to glue your search criteria and block's where clause. You may analize LAST_QUERY property of your block in order to understand how this work. Remember also to set the QUERY_LENGTH property of the EMP_DESC item to the value that could contain the whole Dummy string (otherwise it will give you an error and cut the mar the query).
    Hope this helps.
    Sergey.
    P.S. And set your EMP_DESC database item property to NO.

  • How can BI recognize business event into transactional environment?

    Dear colleagues:
    As I have been looking forward to figure out BW based BAM solutions, such as to implement BW to recognize business event into Transactional applications I just found the TechEd 2008 BPX Community winner proposal Operational BI-Embedded Business Activity Monitoring Drives Sales Growth and Empowers CRM Campaigns, by Anshuman Kumar (congratulations!)  
    However, it will take a long time to September and as I need very much to hurry up on architecting a BW based BAM solution I was wondering if someone else has implemented solution like that to exchange more detailed information, as Event Recognition, or even if Mr. Kumar could provide information regarding his presentation in advance.
    Best Regards
    Waldemar Gonsales u2013 Speedy

    Hi Kiran,
    Depending on your SAP release, you may have a wizard to instantiate an object reference. This basically creates a standard task based on object method System.GenericInstantiate (or something similer - I currently do not have access to the system). You need the object key available in the WF container to do this. It could be tricky if the object key is multipart. Once an object reference is available in the WF container, you can wait for an event of that object.
    Cheers,
    Ramki Maley.

  • Sync seems to be playing up on my iMac itunes.  Events entered into Calendar on my iphone4 fail to appear in iCal after syncing via iTunes.  They must be there however because if I then sync iCal with my ipod via iTunes the missing events appear in Calend

    Sync seems to be playing up when I sync my iPhone 4 with my iMac using iTunes.  Events entered into Calendar on my iPhone do not appear in Calendar on my mac after syncing.  They must be there however since if I then sync Calendar on the mac with iCal on my ipod they appear in calendar on my iPod.  Is it justa display problem or am I being a bit thick??!

    I have the exact same problem as you (minus the coffee incident) where the phone just turned off. Tried everything you have too and now the above link is showing a 404 page... Can you help me out?

  • How can I get my ical events from my iMac to my iPhone? Anything I entered into ical on my iPhone will transfer to ical on iMac when plugged in, but not vice versa.

    How can I get my ical events from my iMac to my iPhone? Anything I entered into ical on my iPhone will transfer to ical on iMac when plugged in, but not vice versa. I think I have changed my iPhone (after looking at similar questions) to iCloud, but it's still not syncing.

    You need to sign into your iCloud account on your Mac, and check the Calendar option. System Preferences>iCloud, sign on your iCloud account, check the apps you want to sync with your device.
    Cheers,
    GB

  • Linking intotype listbox to table in sm30 inorder to maintain field values

    Hi All,
    I got a requirment to create custom infotype with some custom fields adding to stndrd infotype an with also some validations .
    So let me know, How to link intotype listbox to table in sm30 inorder to maintain field values?
    Thanks for the same.

    Hi Vinay,
    The best way would be to assign the search help in the table directly and recreate the maintainance...in this manner the search help would be available in the sm30 already..then using "Ëvents" of the table maintainance generator we can validate the fields entered at the time of saving..if a standard search help already exists then t would be availbel in maintainance......
    to create events -> go to se11 -> utilities -> table maintainance generator -> click '
    then go to environment -> modification -> events ..in the table control..create new entries ....and select the suitable event and write the code in the routine to do validations
    Hope it helps
    Pls check and revert
    Regards
    Byju

  • QALS table update while using MFBF transaction

    Hi ,
    I added new field with Z to QALS table and i want to fill this field when user use MFBF transaction while pushed save button.But i need mat. document number (mblnr) when i find value of new field which i added.I found  EXIT_SAPLQPL1_002 exit which i can change value of QALS table but when i enter into this exit mblnr filed is coming empty.I also tried to find a badi and found INSPECTIONLOT_UPDATE badi's CREATE_BEFORE_UPDATE method.Here i have all values of QALS.But when i change value of new field after this method it becomes empty again.Is there any way to fill this field from mfbf transaction using mblnr?

    Hi Mehul,
    You make use of Wait statement within the BAPI. let the system wait for 2 milliseconds.
    use wait = 2. then try doing the same. I think your error would be resolved.
    Reward points if this helps,
    Kiran

  • Not entering into the loop

    Hi Friends,
    I have written a BDC program to upload salesorder data. But it is not entering into
    <b>LOOP AT ITAB and ENDLOOP.</b>
    Can anyone correct the following code.
    REPORT  SAMPLE NO STANDARD PAGE HEADING.
      TABLES ***********************************************
    TABLES : VBAK, "Sales doc header data
             VBAP, "Sales doc item data
             VBKD. "Sales doc business data
    INTERNAL TABLE DECLERATION ************************
    data : begin of itab occurs 0,
               VBELN LIKE VBAK-VBELN,   "Sales docu no
               AUART LIKE VBAK-AUART,   "sales doc type
               VKORG LIKE VBAK-VKORG,   "sales organization
               VTWEG LIKE VBAK-VTWEG,   "dist channel
               SPART LIKE VBAK-SPART,   "division
               VKGRP LIKE VBAK-VKGRP,   "sales group
               VKBUR LIKE VBAK-VKBUR,   "sales office
               KUNNR LIKE VBAK-KUNNR,   "customer no
               AUDAT LIKE VBAK-AUDAT,   "document date
               WAERK LIKE VBAK-WAERK,   "SD doc currency
               POSNR LIKE VBAP-POSNR,   "Sales doc item no
               PSTYV LIKE VBAP-PSTYV,   "Sales doc item category
               WERKS LIKE VBAP-WERKS,   "Plant
               MATNR LIKE VBAP-MATNR,   "Material No
               BSTKD LIKE VBKD-BSTKD,   "Customer po number
               BSTDK LIKE VBKD-BSTDK,   "Customer PO date
               PRSDT LIKE VBKD-PRSDT,   "Date for pricing and exchange rate
               ZTERM LIKE VBKD-ZTERM,   "Terms of payment key
               INCO1 LIKE VBKD-INCO1,   "incoterms (part1)
               INCO2 LIKE VBKD-INCO2,   "incoterms (part2)
           end of itab.
    data : i_bdcdata like bdcdata occurs 0 with header line.
    data : v_date(8).
    parameters : p_file like rlgrap-filename default 'C:\TEXT.TXT'.
    START OF SELECTION **********************************
    START-OF-SELECTION.
    CALL FUNCTION 'UPLOAD'
    EXPORTING
      CODEPAGE                      = ' '
       FILENAME                      = p_file
       FILETYPE                      = 'DAT'
      ITEM                          = ' '
      FILEMASK_MASK                 = ' '
      FILEMASK_TEXT                 = ' '
      FILETYPE_NO_CHANGE            = ' '
      FILEMASK_ALL                  = ' '
      FILETYPE_NO_SHOW              = ' '
      LINE_EXIT                     = ' '
      USER_FORM                     = ' '
      USER_PROG                     = ' '
      SILENT                        = 'S'
    IMPORTING
      FILESIZE                      =
      CANCEL                        =
      ACT_FILENAME                  =
      ACT_FILETYPE                  =
      TABLES
        DATA_TAB                      = itab.
    EXCEPTIONS
      CONVERSION_ERROR              = 1
      INVALID_TABLE_WIDTH           = 2
      INVALID_TYPE                  = 3
      NO_BATCH                      = 4
      UNKNOWN_ERROR                 = 5
      GUI_REFUSE_FILETRANSFER       = 6
      OTHERS                        = 7
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    loop at itab.
      concatenate itab-bstdk4(2) itab-bstdk6(2) itab-bstdk(4) into v_date.
      refresh i_bdcdata.
      move v_date to itab-bstdk.
      perform mybdcdata.
    CALL TRANSACTION 'VA01' using i_bdcdata MODE 'A' .
    endloop.
    *&      Form  mybdcdata
          text
    form mybdcdata.
      perform mydata using : 'X' 'SAPMV45A' '0101',
                             '' 'VBAK-AUART' itab-auart,
                             '' 'VBAK-VKORG' itab-vkorg,
                             '' 'VBAK-VTWEG' itab-vtweg,
                             '' 'VBAK-SPART' itab-spart,
                             '' 'VBAK-VKBUR' itab-vkbur,
                             '' 'VBAK-VKGRP' itab-vkgrp,
                             '' 'BDC_OKCODE' '/00',
                             'X' 'SAPMV45A' '4001',
                             '' 'VBKD-BSTKD' itab-bstkd,
                             '' 'VBKD-BSTDK' itab-bstdk,
                             '' 'KUAGV-KUNNR' itab-kunnr,
                             '' 'BDC_OKCODE' 'T\02',
                             'X' 'SAPMV45A' '4001',
                             '' 'VBAP-POSNR' itab-posnr,
                             '' 'VBAP-PSTYV' itab-pstyv,
                             '' 'VBAP-MATNR' itab-matnr,
                             '' 'BDC_OKCODE' 'T\04',
                             'X' 'SAPMV45A' '4002',
                             '' 'VBKD-ZTERM' itab-zterm,
                             '' 'VBKD-INCO1' itab-inco1,
                             '' 'VBKD-INCO2' itab-inco2,
                             '' 'BDC_OKCODE' 'T\02',
                             'X' 'SAPMV45A' '4002',
                             '' 'VBAK-AUDAT' itab-audat,
                             '' 'VBAK-WAERK' itab-waerk,
                             '' 'VBKD-PRSDT' itab-prsdt.
                            '' 'BDC_OKCODE' 'T\07'.
    endform.                    "mybdcdata
    *&      Form  mydata
          text
         -->A1         text
         -->A2         text
         -->A3         text
    form mydata using a1 a2 a3.
      if a1 = 'X'.
        clear i_bdcdata.
        i_bdcdata-dynbegin = a1.
        i_bdcdata-program  = a2.
        i_bdcdata-dynpro   = a3.
        append i_bdcdata.
      else.
        clear i_bdcdata.
        i_bdcdata-fnam = a2.
        i_bdcdata-fval = a3.
        append i_bdcdata.
      endif.
    endform.                    "mydata
    waiting for ur reply...
    Thanks
    Raj

    Hi Rajkumar,
    Try this code i have changed in between.
    just cheking itab wether itab  contains records or not.
    if itab has no records check ur flat file.
    REPORT SAMPLE NO STANDARD PAGE HEADING.
    TABLES ***********************************************
    TABLES : VBAK, "Sales doc header data
    VBAP, "Sales doc item data
    VBKD. "Sales doc business data
    INTERNAL TABLE DECLERATION ************************
    data : begin of itab occurs 0,
    VBELN LIKE VBAK-VBELN, "Sales docu no
    AUART LIKE VBAK-AUART, "sales doc type
    VKORG LIKE VBAK-VKORG, "sales organization
    VTWEG LIKE VBAK-VTWEG, "dist channel
    SPART LIKE VBAK-SPART, "division
    VKGRP LIKE VBAK-VKGRP, "sales group
    VKBUR LIKE VBAK-VKBUR, "sales office
    KUNNR LIKE VBAK-KUNNR, "customer no
    AUDAT LIKE VBAK-AUDAT, "document date
    WAERK LIKE VBAK-WAERK, "SD doc currency
    POSNR LIKE VBAP-POSNR, "Sales doc item no
    PSTYV LIKE VBAP-PSTYV, "Sales doc item category
    WERKS LIKE VBAP-WERKS, "Plant
    MATNR LIKE VBAP-MATNR, "Material No
    BSTKD LIKE VBKD-BSTKD, "Customer po number
    BSTDK LIKE VBKD-BSTDK, "Customer PO date
    PRSDT LIKE VBKD-PRSDT, "Date for pricing and exchange rate
    ZTERM LIKE VBKD-ZTERM, "Terms of payment key
    INCO1 LIKE VBKD-INCO1, "incoterms (part1)
    INCO2 LIKE VBKD-INCO2, "incoterms (part2)
    end of itab.
    data : i_bdcdata like bdcdata occurs 0 with header line.
    data : v_date(8).
    parameters : p_file like rlgrap-filename default 'C:\TEXT.TXT'.
    START OF SELECTION **********************************
    START-OF-SELECTION.
    <b>perform upload_data.
    if not itab[ ] is initial .
    perform  bdc_populate.</b>
    <b>else.
    write :/  ' no records in itab '.
    endif.</b>
    <b>form upload_data.</b>
    CALL FUNCTION 'UPLOAD'
    EXPORTING
    CODEPAGE = ' '
    FILENAME = p_file
    FILETYPE = 'DAT'
    ITEM = ' '
    FILEMASK_MASK = ' '
    FILEMASK_TEXT = ' '
    FILETYPE_NO_CHANGE = ' '
    FILEMASK_ALL = ' '
    FILETYPE_NO_SHOW = ' '
    LINE_EXIT = ' '
    USER_FORM = ' '
    USER_PROG = ' '
    SILENT = 'S'
    IMPORTING
    FILESIZE =
    CANCEL =
    ACT_FILENAME =
    ACT_FILETYPE =
    TABLES
    DATA_TAB = itab.
    EXCEPTIONS
    CONVERSION_ERROR = 1
    INVALID_TABLE_WIDTH = 2
    INVALID_TYPE = 3
    NO_BATCH = 4
    UNKNOWN_ERROR = 5
    GUI_REFUSE_FILETRANSFER = 6
    OTHERS = 7
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    <b>endform.</b>
    form bdc_populate.
    loop at itab.
    concatenate itab-bstdk4(2) itab-bstdk6(2) itab-bstdk(4) into v_date.
    refresh i_bdcdata.
    move v_date to itab-bstdk.
    perform mybdcdata.
    CALL TRANSACTION 'VA01' using i_bdcdata MODE 'A' .
    endloop.
    <b>endform.</b>
    *& Form mybdcdata
    text
    form mybdcdata.
    perform mydata using : 'X' 'SAPMV45A' '0101',
    '' 'VBAK-AUART' itab-auart,
    '' 'VBAK-VKORG' itab-vkorg,
    '' 'VBAK-VTWEG' itab-vtweg,
    '' 'VBAK-SPART' itab-spart,
    '' 'VBAK-VKBUR' itab-vkbur,
    '' 'VBAK-VKGRP' itab-vkgrp,
    '' 'BDC_OKCODE' '/00',
    'X' 'SAPMV45A' '4001',
    '' 'VBKD-BSTKD' itab-bstkd,
    '' 'VBKD-BSTDK' itab-bstdk,
    '' 'KUAGV-KUNNR' itab-kunnr,
    '' 'BDC_OKCODE' 'T\02',
    'X' 'SAPMV45A' '4001',
    '' 'VBAP-POSNR' itab-posnr,
    '' 'VBAP-PSTYV' itab-pstyv,
    '' 'VBAP-MATNR' itab-matnr,
    '' 'BDC_OKCODE' 'T\04',
    'X' 'SAPMV45A' '4002',
    '' 'VBKD-ZTERM' itab-zterm,
    '' 'VBKD-INCO1' itab-inco1,
    '' 'VBKD-INCO2' itab-inco2,
    '' 'BDC_OKCODE' 'T\02',
    'X' 'SAPMV45A' '4002',
    '' 'VBAK-AUDAT' itab-audat,
    '' 'VBAK-WAERK' itab-waerk,
    '' 'VBKD-PRSDT' itab-prsdt.
    '' 'BDC_OKCODE' 'T\07'.
    endform. "mybdcdata
    *& Form mydata
    text
    -->A1 text
    -->A2 text
    -->A3 text
    form mydata using a1 a2 a3.
    if a1 = 'X'.
    clear i_bdcdata.
    i_bdcdata-dynbegin = a1.
    i_bdcdata-program = a2.
    i_bdcdata-dynpro = a3.
    append i_bdcdata.
    else.
    clear i_bdcdata.
    i_bdcdata-fnam = a2.
    i_bdcdata-fval = a3.
    append i_bdcdata.
    endif.
    endform. "mydata
    Regards.
    Francis.

  • Today's date dynamically entered into text field that user enters additional text into same field.

    Trying to have today's date dynamically entered into a repeating table row textfield when the button is clicked to create each repeating row. The user can then enter addtional text into the same text field next to the date.
    Example:
    [4/25/2012] This is the text the user entered.
    Today's date is populated in each update row created when the "Update Row" button is clicked.
    The following script works but only for the first instance, not the second, third, forth, etc...
    Click event: (JavaScript, client)
    this.resolveNode('Table2._RowB').addInstance(1);
    xfa.resolveNode("Table2.RowB.#subform.Update").rawValue
    Thank you,
    ~Don

    Hi Don,
    Does this solution cover the above problem? https://acrobat.com/#d=VjJ-YsXLKmV6QU84JrAAIw
    Niall

  • Alter a BAPI Result Table, how to get into the display "loop" ?

    Hello all,
    i have a problem regarding the result rows of a RFC/BAPI Call.
    There are three views, let's say 1,2,3. In View 1, i call a BAPI, and display the results in a table in View 2. I added a button in each row, which calls View 3 and displays some details concerning the selected row.
    I now want to store a flag for each row, that has been displayed in this way.
    In View 3 i store the key value of the displayed row in an own value node in the context.
    When i go back from View 3 to View 2, i want to see that flag (in an extra column) in every row, that has been selected in this session.
    So i do not know, how to alter a single row in the BAPI result table, how to get into the "loop" that is used by WD to display the table.
    already tried a supply function, but i was not able to alter single rows.
    Any suggestions/tips or perhaps code fragments of working supply functions ?
    Thank you !

    Hello,
    I'm not sure whether I understood your problem correctly, but I will try to give an answer.
    The easiest way I see is to copy the RFC Results to a Component Controller Context structure with an additional Flag field. You can use WDCopyService for copying.
    Then on the event of selecting you set your flag as appropriate for you (e.g. if you want to use an image as flag you set the Image path) on the current element of your table. Then display View 3.
    On going back View 2 should show now the new flag values...
    The trick is to copy the values (as at Time structures can not be expandend with new fields) and set the Flag on the onSelect event.
    Hope this helps,
    Frank

  • Report using internal table events

    Hi,
    i have an internal table with  the fields 1. profitcenter 2. company code 3. gl account 4. amount
    for each profit center i need to seggregate accounts based on company code.
    the report should look like the one below.
    please suggest some code using internal table events at new , at end etc. as im not using alv. your help will be rewarded
    regards,
    ravi.
    -Profitcenter-companycodeglaccount-amount---
    -pfcenter1----
    glaccount1-1000---
    glaccount2-2000---
    4444-total--3000---
    glaccount1-4000---
    glaccount2-1000---
    3333-total--5000---
    -profitcentre1*total8000---
    profitcentre2.........

    Hi.
    TYPES: BEGIN OF G_I_DATA,
             PROFIT(4)   TYPE C,
             COMPANY(4)  TYPE C,
             ACCOUNT(10) TYPE C,
             AMOUNT      TYPE P,
           END OF G_I_DATA.
    DATA: G_IT_DATA TYPE TABLE OF G_I_DATA,
          G_WA_DATA TYPE G_I_DATA.
    DATA: G_SUM_COMPANY  TYPE P,
          G_SUM_PROFIT   TYPE P,
          G_AMOUNT       TYPE P.
      G_WA_DATA-PROFIT = '0001'.
      G_WA_DATA-COMPANY = '1111'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT1'.
      G_WA_DATA-AMOUNT = 2000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0001'.
      G_WA_DATA-COMPANY = '1111'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT2'.
      G_WA_DATA-AMOUNT = 3000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0001'.
      G_WA_DATA-COMPANY = '2222'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT1'.
      G_WA_DATA-AMOUNT = 4000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0001'.
      G_WA_DATA-COMPANY = '2222'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT2'.
      G_WA_DATA-AMOUNT = 5000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0002'.
      G_WA_DATA-COMPANY = '1111'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT1'.
      G_WA_DATA-AMOUNT = 2000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0002'.
      G_WA_DATA-COMPANY = '1111'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT2'.
      G_WA_DATA-AMOUNT = 3000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0002'.
      G_WA_DATA-COMPANY = '2222'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT1'.
      G_WA_DATA-AMOUNT = 4000.
      APPEND G_WA_DATA TO G_IT_DATA.
      G_WA_DATA-PROFIT = '0002'.
      G_WA_DATA-COMPANY = '2222'.
      G_WA_DATA-ACCOUNT = 'ACCOUNT2'.
      G_WA_DATA-AMOUNT = 5000.
      APPEND G_WA_DATA TO G_IT_DATA.
      SORT G_IT_DATA BY PROFIT COMPANY ACCOUNT.
      WRITE: /6 'ProfitCenter', 20 'CompanyCode',
              34 'Glaccount', 48 'Amount'.
      WRITE: /6 SY-ULINE(50).
      LOOP AT G_IT_DATA INTO G_WA_DATA.
        AT NEW PROFIT.
          WRITE: /6 G_WA_DATA-PROFIT.
        ENDAT.
        G_AMOUNT = G_WA_DATA-AMOUNT.
        AT NEW ACCOUNT.
          WRITE: /34 G_WA_DATA-ACCOUNT,
                 48  G_AMOUNT.
        ENDAT.
        G_SUM_PROFIT = G_SUM_PROFIT + G_WA_DATA-AMOUNT.
        G_SUM_COMPANY = G_SUM_COMPANY + G_WA_DATA-AMOUNT.
        AT END OF COMPANY.
          WRITE: /20 G_WA_DATA-COMPANY,
                  34 'Totle',
                  48 G_SUM_COMPANY.
          CLEAR G_SUM_COMPANY.
          WRITE: /6 '*******'.
        ENDAT.
        AT END OF PROFIT.
          WRITE: /6 G_WA_DATA-PROFIT,
                  20 'Totle',
                  48 G_SUM_PROFIT.
          CLEAR G_SUM_PROFIT.
          WRITE: /6 '*************************************'.
        ENDAT.
      ENDLOOP.

  • How to enter a transaction by double-clicking output ?

    I have an itab with fields vbeln etc etc.
    I have a simple list on the output table based on this itab. Now if the user double clicks on this list, he/she should be able to enter VA02 transaction after which if he/she makes changes and save, he/she should be able to come back to the output screen.
    Can you please tell me where should I modify reg. this?
    Thanks a lot.

    Hi
    Try this
    DATA: BEGIN OF ITAB OCCURS 0,
           VBELN TYPE VBELN,
           MATNR TYPE MATNR,
           NETWR TYPE NETWR,
         END   OF ITAB.
    START-OF-SELECTION.
      PERFORM ACTION.
    AT LINE-SELECTION.
      SET PARAMETER ID 'AUN' FIELD ITAB-VBELN.
      CALL TRANSACTION 'VA02' AND SKIP FIRST SCREEN.
    *&      Form  action
          text
    FORM ACTION.
      IF NOT ITAB[] IS INITIAL.
        LOOP AT ITAB.
          FORMAT HOTSPOT ON.
          WRITE: AT /10 ITAB-VBELN,
                        ITAB-MATNR,
                     39 ITAB-NETWR.
          HIDE ITAB-MATNR.
          FORMAT HOTSPOT OFF.
          AT LAST.
            SUM.
            WRITE: /39 ITAB-MATNR.
          ENDAT.
        ENDLOOP.
      ENDIF.
    ENDFORM.                    "ACTION
    Max

Maybe you are looking for

  • Vendor master file report.

    Dear All, I always use S_ALR_87012089 display changes to vendors to check vendor master data if they are created or updated in accordance with proper approvals (not a workflow in SAP). Recently, I see other tcode S_ALR_87012090, but do not know what

  • CONTROL OF SERVICE PO

    Hi, We have one problem. When a Service PR is generated it has 1 AU at the header level qty where as it as service line item at the Service level with each service item having some qty. Now once this PR is adopted to create the PO, if user changes th

  • How to remove Space

    Hi  group, I have one string with length 15 ,sometimes I am getting this fields with in between sapces and hyphen(-) ,how to remove these spaces and hyphen using JAVA in UDF. Can any suggest

  • Help with Web Services

    hi, am trying to call a web service from a particular WSDL, i need to use JAX-WS 2.0 as part of this assignment am currently working on, but i just cannot put my head around it and where to start,, would i need to just write a client that would call

  • Script for no sound when receiving spam

    Hi there, I'm looking for a script for Apple Mail that shuts off sound when a message that's labeled as spam comes in. I have several e-mail accounts running in Apple Mail. It happens often that while checking for new mail only spam comes in. It woul