Updating the line items

Hi, I am unable to update the Business Area .
I have some blank Busines Areas i should update the Business Area line items  same as According to the belnr(header)
REPORT zfir_vendorwise_grir_balances NO STANDARD PAGE HEADING
                        LINE-SIZE 142
                        LINE-COUNT 65.
TABLES: bsis,bkpf,bseg,ekko,lfa1.
TYPE-POOLS: slis.
CONSTANTS:
gc_formname_top_of_page TYPE slis_formname VALUE 'TOP_OF_PAGE'.
DATA: gt_fieldcat TYPE slis_t_fieldcat_alv,
      gs_layout   TYPE slis_layout_alv ,
      gs_print    TYPE slis_print_alv,
      gt_sort     TYPE slis_t_sortinfo_alv ,
      gt_filter   TYPE slis_t_filter_alv,
      gt_sp_group TYPE slis_t_sp_group_alv,
      gt_alv_graphics TYPE dtc_t_tc,
      gt_excluding  TYPE slis_t_extab ,
      gt_events   TYPE slis_t_event .
DATA: g_repid LIKE sy-repid.
DATA: gt_list_top_of_page TYPE slis_t_listheader.
DATA:       g_boxnam TYPE slis_fieldname VALUE  'BOX',
            p_f2code LIKE sy-ucomm       VALUE  '&ETA',
            p_lignam TYPE slis_fieldname VALUE  'LIGHTS',
            g_save(1) TYPE c,
            g_default(1) TYPE c,
            g_exit(1) TYPE c,
            gx_variant LIKE disvariant,
            g_variant LIKE disvariant.
DATA : g_user_command(30) VALUE 'USER_COMMAND'.
DATA : g_status_set(30)  VALUE 'PF_STATUS_SET'.
DATA: BEGIN OF it_final OCCURS 0,
      awkey TYPE awkey,
      grir(10) TYPE c,
      bukrs LIKE bsis-bukrs,
      hkont LIKE bsis-hkont,
      gjahr LIKE bsis-gjahr,
      belnr LIKE bsis-belnr,
      budat LIKE bsis-budat,
      waers LIKE bsis-waers,
      xblnr LIKE bsis-xblnr,
      blart LIKE bkpf-blart,
      buzei like bseg-buzei,
      bschl LIKE bseg-bschl,
      shkzg LIKE bseg-shkzg,
      gsber LIKE bseg-gsber,
      dmbtr LIKE bseg-dmbtr,
      wrbtr LIKE bsis-wrbtr,
      sgtxt LIKE bseg-sgtxt,
      ebeln LIKE bseg-ebeln,
      lifnr LIKE ekko-lifnr,
      ps_psp_pnr LIKE ekkn-ps_psp_pnr,
      name1 LIKE addr1_data-name1,
      END OF it_final.
DATA : it_po LIKE it_final OCCURS 0 WITH HEADER LINE.
DATA : it_ebeln LIKE it_final OCCURS 0 WITH HEADER LINE.
DATA : it_awkey LIKE it_final OCCURS 0 WITH HEADER LINE.
DATA : wa_final LIKE LINE OF it_final.
DATA : BEGIN OF it_lifnr OCCURS 0,
        ebeln TYPE ebeln,
        lifnr TYPE lifnr,
END OF it_lifnr.
DATA : BEGIN OF it_name1 OCCURS 0,
        lifnr TYPE lifnr,
        name1 TYPE name1,
END OF it_name1.
DATA : hmin TYPE bseg-hkont.
DATA : hmax TYPE bseg-hkont.
DATA: idx TYPE sy-tabix.
DATA:  temp_gsber TYPE bseg-gsber.
DATA:  temp_ebeln TYPE bseg-ebeln.
DATA : temp_gjahr TYPE bseg-gjahr.
DATA : temp_belnr TYPE bseg-belnr.
DATA : temp_lifnr TYPE bseg-lifnr.
*DEFINING THE SELECTION-CRITERIA.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETERS: p_bukrs LIKE skb1-bukrs OBLIGATORY.
SELECT-OPTIONS: s_gsber FOR bseg-gsber OBLIGATORY.
SELECT-OPTIONS: s_hkont FOR bseg-hkont OBLIGATORY.
PARAMETERS: p_lifnr LIKE ekko-lifnr.
PARAMETERS: p_budat LIKE bkpf-budat OBLIGATORY.
SELECTION-SCREEN END OF BLOCK b1.
AT SELECTION-SCREEN ON s_hkont.
  CHECK s_hkont-low LT 250301 OR s_hkont-high GT 250500.
  MESSAGE e000(zm) WITH 'PLEASE SELECT A GRIR CLEARING ACCOUNT BETWEEN'
                        '250301 AND 250500'.
*INITIALIZATION.
INITIALIZATION.
  g_repid = sy-repid.
*START-OF-SELECTION.
START-OF-SELECTION.
  PERFORM select_data.
  PERFORM display_data.
  PERFORM list_display.
*&      Form  select_data
      text
-->  p1        text
<--  p2        text
FORM select_data .
*selecting open item details
  SELECT bukrs  hkont  gjahr   belnr buzei
         budat  waers  xblnr   blart
         bschl  shkzg  gsber   dmbtr
         wrbtr  sgtxt
     FROM bsis
        INTO CORRESPONDING FIELDS OF TABLE it_final
        WHERE bukrs EQ p_bukrs
              AND hkont BETWEEN  '0000250301' AND  '0000250500'
              AND budat LE p_budat AND ( blart EQ 'WE' OR
                                         blart EQ 'RE' OR
                                         blart EQ 'SA' OR
                                         blart EQ 'EI').
*selecting closed/cleared item details
  SELECT bukrs  hkont gjahr belnr buzei budat
         waers  xblnr blart bschl shkzg
         gsber  dmbtr wrbtr sgtxt
     FROM bsas
        APPENDING CORRESPONDING FIELDS OF TABLE it_final
        WHERE bukrs EQ p_bukrs
        AND hkont BETWEEN '0000250301' AND  '0000250500'
        AND budat LE p_budat
        AND blart IN ('WE', 'RE','SA','EI')
        AND augdt GE p_budat.
  SORT it_final BY belnr gsber DESCENDING.
  CLEAR: temp_belnr, temp_gsber.
update blank business areas
LOOP AT it_final .
IF temp_gsber IN s_gsber AND it_final-belnr = temp_belnr.
     IF it_final-gsber = ' '.
       it_final-gsber = temp_gsber.
     ENDIF.
   ENDIF.
if it_final-gsber eq space or it_final-gsber in s_gsber.
     wa_final-gsber = it_final-gsber.
     wa_final-belnr = it_final-belnr.
     modify it_final from wa_final transporting gsber.
else.
     wa_final-gsber = it_final-gsber.
     wa_final-belnr = it_final-belnr.
     modify it_final from wa_final transporting gsber.
endif.
*clear wa_final.
endloop.
LOOP AT it_final.
   IF temp_gsber IN s_gsber AND it_final-belnr = temp_belnr.
     IF it_final-gsber = ' '.
       it_final-gsber = temp_gsber.
     ENDIF.
     IF it_final-lifnr = ' '.
       it_final-lifnr = temp_lifnr.
     ENDIF.
     IF it_final-belnr = ' '.
       it_final-belnr = temp_belnr.
     ENDIF.
   ENDIF.
   IF it_final-gsber EQ space OR it_final-gsber IN s_gsber.
     CLEAR: temp_belnr, temp_gsber,temp_lifnr.
     temp_belnr = it_final-belnr.
     temp_gsber = it_final-gsber.
     temp_lifnr = it_final-lifnr.
   ELSE.
     CLEAR : temp_belnr, temp_gsber,temp_lifnr.
   ENDIF.
   MODIFY it_final TRANSPORTING gsber.
ENDLOOP.
  sort it_final by belnr buzei.
loop at it_final.
on change of it_final-belnr.
clear temp_belnr.
clear temp_gsber.
clear temp_lifnr.
temp_belnr = it_final-belnr.
temp_gsber = it_final-gsber.
temp_lifnr = it_final-lifnr.
endon.
if it_final-gsber is initial.
  it_final-gsber = temp_gsber.
*modify it_final transporting gsber.
endif.
if it_final-lifnr is initial.
  it_final-lifnr = temp_lifnr.
*modify it_final transporting lifnr.
endif.
modify it_final transporting gsber lifnr where belnr = temp_belnr.
endloop.
*deleting entries which are not as per input parameter for business area
DELETE it_final WHERE  gsber NOT IN s_gsber .
loop at it_final.
  if s_gsber-low ne '' and s_gsber-high ne ''.
  delete it_final where gsber not in s_gsber.
elseif s_gsber-low ne '' and s_gsber-high eq ''.
delete it_final  where gsber ne s_gsber-low.
endif.
endloop.
*initialising internal tables
  it_awkey[] = it_final[].
  it_po[] = it_final[].
  it_ebeln[] = it_final[].
  IF it_final[] IS NOT INITIAL.
*selecting purchase doc details
    SELECT bukrs  hkont  gjahr   belnr
                   bschl  shkzg  gsber   dmbtr
         wrbtr  sgtxt ebeln
           FROM bseg  INTO CORRESPONDING FIELDS OF TABLE it_ebeln
           FOR ALL ENTRIES IN it_final
            WHERE bukrs = p_bukrs
              AND belnr = it_final-belnr
              AND gjahr = it_final-gjahr
              AND hkont = it_final-hkont.
*selecting the GR/IR number from BKPF
    SELECT  bukrs    gjahr   belnr
         budat  waers  xblnr   blart
         awkey
        FROM bkpf
      INTO CORRESPONDING FIELDS OF  TABLE it_awkey
          FOR ALL ENTRIES IN it_final
    WHERE bukrs EQ it_final-bukrs
          AND gjahr EQ it_final-gjahr
          AND belnr EQ it_final-belnr.
  ENDIF.
  IF it_ebeln[] IS NOT INITIAL.
*selecting WBS element
    SELECT   ebeln  gsber
          ps_psp_pnr
      FROM ekkn
      INTO CORRESPONDING FIELDS OF TABLE it_po
      FOR ALL ENTRIES IN it_ebeln
      WHERE ebeln = it_ebeln-ebeln.
*selecting vendor
    SELECT bukrs ebeln lifnr
      FROM ekko
      INTO CORRESPONDING FIELDS OF TABLE it_lifnr
      FOR ALL ENTRIES IN it_ebeln
      WHERE ebeln = it_ebeln-ebeln.
  ENDIF.
  IF it_lifnr[] IS NOT INITIAL.
*selecting vendor name
    SELECT lifnr name1
        FROM lfa1
        INTO CORRESPONDING FIELDS OF  TABLE  it_name1
        FOR ALL ENTRIES IN it_lifnr
        WHERE lifnr EQ it_lifnr-lifnr.
  ENDIF.
  LOOP AT it_final.
    idx = sy-tabix.
*retrieving purchase doc
    READ TABLE it_ebeln WITH KEY belnr = it_final-belnr
                                 gjahr = it_final-gjahr
                                 hkont = it_final-hkont.
    IF sy-subrc EQ 0.
      READ TABLE it_final INDEX idx.
      it_final-ebeln = it_ebeln-ebeln.
      MODIFY it_final INDEX sy-tabix.
    ENDIF.
*retrieving WBS element
    READ TABLE it_po WITH KEY ebeln = it_final-ebeln.
    IF sy-subrc EQ 0.
      READ TABLE it_final INDEX idx.
      it_final-ps_psp_pnr = it_po-ps_psp_pnr.
      MODIFY it_final INDEX sy-tabix.
    ENDIF.
calculating amount based on debit/credit
    IF it_final-shkzg = 'H'.
      it_final-dmbtr = 0 - it_final-dmbtr.
      it_final-wrbtr = 0 - it_final-wrbtr.
    ENDIF.
    MODIFY it_final INDEX idx.
  ENDLOOP.
  CLEAR idx.
  SORT it_final BY belnr ebeln DESCENDING.
*updating blank purchase doc numbers
  CLEAR: temp_belnr, temp_ebeln,temp_gjahr.
  DATA: w_idx LIKE sy-tabix.
  LOOP AT it_final.
    w_idx = sy-tabix.
*updating blank purchase docs
    IF it_final-gjahr = temp_gjahr AND it_final-belnr = temp_belnr.
      IF it_final-ebeln = ' '.
        it_final-ebeln = temp_ebeln.
      ENDIF.
    ENDIF.
    IF it_final-ebeln NE ' ' .
      CLEAR: temp_belnr, temp_ebeln, temp_gjahr.
      temp_belnr = it_final-belnr.
      temp_ebeln = it_final-ebeln.
      temp_gjahr = it_final-gjahr.
    ELSE.
      CLEAR : temp_belnr, temp_ebeln, temp_gjahr.
    ENDIF.
    MODIFY it_final TRANSPORTING ebeln.
*retrieving vendor
    READ TABLE it_lifnr WITH KEY ebeln = it_final-ebeln.
    IF sy-subrc EQ 0.
      READ TABLE it_final INDEX w_idx.
      it_final-lifnr = it_lifnr-lifnr.
      MODIFY it_final INDEX sy-tabix.
    ENDIF.
*retrieving GRIR number
    READ TABLE it_awkey WITH KEY belnr = it_final-belnr
                                 gjahr = it_final-gjahr
                                 bukrs = it_final-bukrs.
    IF sy-subrc EQ 0.
      READ TABLE it_final INDEX w_idx.
      it_final-awkey = it_awkey-awkey.
      MODIFY it_final INDEX sy-tabix.
    ENDIF.
*retrieving vendor name
    READ TABLE it_name1 WITH KEY lifnr = it_final-lifnr.
    IF sy-subrc EQ 0.
      READ TABLE it_final INDEX w_idx.
      it_final-name1 = it_name1-name1..
      MODIFY it_final INDEX sy-tabix.
    ENDIF.
  ENDLOOP.
*deleting entries which are not per input parameters
  DELETE it_final WHERE hkont NOT IN s_hkont.
  IF p_lifnr NE ' '.
    DELETE it_final WHERE lifnr NE p_lifnr.
  ENDIF.
for selecting the grir number which is the first 10 digits of reference key and
selecting vendor name
  LOOP AT it_final.
    MOVE it_final-awkey+0(10) TO it_final-grir.
    MODIFY it_final INDEX sy-tabix.
  ENDLOOP.
  SORT it_final BY hkont belnr.
deleting entries where purchase doc is blank.
  DELETE it_final WHERE ebeln EQ ' '.
ENDFORM.                    " select_data
*&      Form  build_fieldcat
      text
-->  p1        text
<--  p2        text
FORM e01_fieldcat_init  USING gt_fieldcat TYPE slis_t_fieldcat_alv.
  DATA: ls_fieldcat TYPE slis_fieldcat_alv.
  DATA: gs_sort TYPE slis_sortinfo_alv.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'HKONT'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '1'.
  ls_fieldcat-seltext_l    = 'ACCOUNT'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'BSCHL'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '2'.
  ls_fieldcat-seltext_l    = 'POSTING KEY'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'BLART'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '3'.
  ls_fieldcat-seltext_l    = 'DOC TYPE'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'BELNR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '4'.
  ls_fieldcat-seltext_l    = 'DOC NUMBER'.
  ls_fieldcat-hotspot(1)   = 'X'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'BUDAT'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '5'.
  ls_fieldcat-seltext_l    = 'POSTING DATE'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'XBLNR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '6'.
  ls_fieldcat-seltext_l    = 'REF. DOC NO'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'EBELN'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '7'.
  ls_fieldcat-seltext_l    = 'PURCHASE DOC NO'.
  ls_fieldcat-hotspot(1)   = 'X'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'GSBER'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '8'.
  ls_fieldcat-seltext_l    = 'BUSINESS AREA'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'DMBTR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '9'.
  ls_fieldcat-seltext_l    = 'AMOUNT(LC)'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'WRBTR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '10'.
  ls_fieldcat-seltext_l    = 'AMOUNT(DC)'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'WAERS'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '11'.
  ls_fieldcat-seltext_l    = 'CURRENCY'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'GJAHR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '14'.
  ls_fieldcat-seltext_l    = 'Fiscal year'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'GRIR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '14'.
  ls_fieldcat-seltext_l    = 'GR/IR Number'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'LIFNR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '12'.
  ls_fieldcat-seltext_l    = 'VENDOR NO'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'PS_PSP_PNR'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '13'.
  ls_fieldcat-seltext_l    = 'WBS Element'.
  APPEND ls_fieldcat TO gt_fieldcat.
  CLEAR ls_fieldcat.
  ls_fieldcat-fieldname    = 'NAME1'.
  ls_fieldcat-tabname    = 'IT_FINAL'.
  ls_fieldcat-col_pos      = '14'.
  ls_fieldcat-seltext_l    = 'VENDOR NAME'.
  APPEND ls_fieldcat TO gt_fieldcat.
ENDFORM.                    " build_fieldcat
*&      Form  LIST_DISPLAY
      text
-->  p1        text
<--  p2        text
FORM list_display .
  gs_layout-colwidth_optimize(1)  = 'X'.
  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
      i_background_id         = 'ALV_BACKGROUND'
      i_callback_program      = g_repid
      i_callback_user_command = 'USER_COMMAND'
      i_structure_name        = 'IT_FINAL'
      is_layout               = gs_layout
      it_fieldcat             = gt_fieldcat[]
      it_special_groups       = gt_sp_group[]
      it_sort                 = gt_sort[]
      it_filter               = gt_filter[]
      i_save                  = g_save
      is_variant              = g_variant
      it_events               = gt_events[]
      is_print                = gs_print
      it_alv_graphics         = gt_alv_graphics[]
      it_excluding            = gt_excluding
    TABLES
      t_outtab                = it_final.
ENDFORM.                    " LIST_DISPLAY
*&      Form  USER_COMMAND
FORM user_command USING i_ucomm  LIKE sy-ucomm
                        is_selfield TYPE slis_selfield.     "#EC CALLED
  CASE i_ucomm.
    WHEN '&IC1'.                        " Pick(Double-click)
      CASE is_selfield-fieldname.
        WHEN 'BELNR'.
          CLEAR it_final.
          READ TABLE it_final INDEX is_selfield-tabindex.
          IF sy-subrc EQ 0.
          FI Document number
            SET PARAMETER ID 'BLN' FIELD it_final-belnr.
          Display Document
            CALL TRANSACTION 'FB03' AND SKIP FIRST SCREEN.
          ENDIF.
        WHEN 'EBELN'.
          CLEAR it_final.
          READ TABLE it_final INDEX is_selfield-tabindex.
          IF sy-subrc EQ 0.
          PO number
            IF it_final-ebeln NE ' '.
              SET PARAMETER ID 'BES' FIELD it_final-ebeln.
          Display Document
              CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN.
            ENDIF.
          ENDIF.
      ENDCASE.
  ENDCASE.
ENDFORM.                    "user_command
*&      Form  display_data
      text
-->  p1        text
<--  p2        text
FORM display_data .
  g_repid = sy-repid.
  PERFORM e01_fieldcat_init  USING gt_fieldcat[].
  PERFORM eventtab_build CHANGING gt_events.
  PERFORM e04_comment_build USING gt_list_top_of_page[].
ENDFORM.                    " display_data
*&      Form  eventtab_build
      text
     <--P_GT_EVENTS  text
FORM eventtab_build CHANGING lt_events TYPE slis_t_event.
  CONSTANTS:
    gc_formname_top_of_page TYPE slis_formname VALUE 'TOP_OF_PAGE'.
  DATA: ls_event TYPE slis_alv_event.
  CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
    EXPORTING
      i_list_type = 0
    IMPORTING
      et_events   = lt_events.
  READ TABLE lt_events WITH KEY name = slis_ev_top_of_page
  INTO ls_event.
  IF sy-subrc = 0.
    MOVE gc_formname_top_of_page TO ls_event-form.
    APPEND ls_event TO lt_events.
  ENDIF.
ENDFORM.                    " eventtab_build
*&      Form  e04_comment_build
      text
     -->P_GT_LIST_TOP_OF_PAGE[]  text
FORM e04_comment_build  USING e04_lt_top_of_page TYPE slis_t_listheader.
  DATA : v_time(10) TYPE c.
  DATA: ls_line TYPE slis_listheader.
  DATA : v_text(50) TYPE c.
  DATA : v_date_low(10)  TYPE c,
         v_date_high(10)  TYPE c.
  CONCATENATE 'GR/IR Report' ' '
  INTO v_text SEPARATED BY space.
  CLEAR ls_line.
  ls_line-typ  = 'H'.
  ls_line-info = v_text.
  APPEND ls_line TO e04_lt_top_of_page.
ENDFORM.                    " e04_comment_build
*&      Form  top_of_page
      text
FORM top_of_page.
  CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
      it_list_commentary = gt_list_top_of_page.
ENDFORM   .                    "TOP_OF_PAGE

sorry amit,
but i've no time to read your full coding.
you <b>cannot</b> update business area in fi-document.
(it's not changeable field !)
so reverse the document with fb08 and post document new with correct b.a.
A.
Message was edited by: Andreas Mann

Similar Messages

  • BAPI_PO_CHANGE to update the Price for the line item not updating the Price

    Hi,
    I am using BAPI_PO_CHANGE to update the Price for the line item. This BAPI is not updating the Price. I am using external cummit also, but the BAPI is not updating price.
    I am passing following data to the BAPI.
    Plant: CQ11
    PO                   Material                Price
    4500002142     TEST_BATCH     12
    Please provide suggestion.
    Regards,
    Jubin.

    Hi,
    check this link...this has sample code
    [http://www.sap-img.com/abap/sample-abap-code-on-bapi-po-change.htm]
    Regards,
    Surinder

  • WebPart is raising the following error "Invalid data has been used to update the list item.The field you are trying to update may be read only"

    I have created a farm solution and then i deploy it to SharePoint server, the code looks as follow, and i use it to update a page info values (as the current page values represents old info):-
    [ToolboxItemAttribute(false)]
    public partial class VisualWebPart1 : WebPart
    // Uncomment the following SecurityPermission attribute only when doing Performance Profiling using
    // the Instrumentation method, and then remove the SecurityPermission attribute when the code is ready
    // for production. Because the SecurityPermission attribute bypasses the security check for callers of
    // your constructor, it's not recommended for production purposes.
    // [System.Security.Permissions.SecurityPermission(System.Security.Permissions.SecurityAction.Assert, UnmanagedCode = true)]
    public VisualWebPart1()
    protected override void OnInit(EventArgs e)
    base.OnInit(e);
    InitializeControl();
    using (SPSite site = new SPSite(SPContext.Current.Site.Url))
    using (SPWeb web = site.OpenWeb())
    SPList list = web.Lists["Pages"];
    web.AllowUnsafeUpdates = true;
    foreach (SPListItem items in list.Items)
    items["Author"] = "SharePoint";
    items["Created"] = "01/08/2014 01:44 PM";
    items.Update();
    list.Update();
    web.AllowUnsafeUpdates = false;
    protected void Page_Load(object sender, EventArgs e)
    but when i try adding this web part to a page i got the following error:-
    Invalid data has been used to update the list item.The field you are trying to update may be read only
    so can anyone advice?

    i only changed lines bitween 
    web.AllowUnsafeUpdates = true;
    and
    web.AllowUnsafeUpdates = false;
    and other parts of code remains without change
    so it will updates all pages in current web
    yaşamak bir eylemdir

  • Invalid data has been used to update the list item. The field you are trying to update may be read only (Lookup Field).

    Hi.
    I am getting below error while adding value to look-up field.
    Invalid data has been used to update the list item. The field you are trying to update may be read only.
    I have tried many forums ans post but didn't come to know what's the root cause of issue. I am also posting Code for creating and adding lookup field.
    CAML to create lookup field (It works Fine)
    string lkproductNumber = "<Field Type='Lookup' DisplayName='Product Number' StaticName='ProductNumber' ReadOnly='FALSE' List='" + pNewMaster.Id + "' ShowField='Product_x0020_Number' />";
    Code to insert value to lookup field
    ClientContext client = new ClientContext(SiteUrl);
    client.Load(client.Web);
    client.Credentials = new NetworkCredential(this.UserName, this.Password, this.Domain);
    // Lookup Lists
    List pmList = client.Web.Lists.GetByTitle("Product_Master");
    //List Conatining Lookup Columns
    List piList = client.Web.Lists.GetByTitle("Product_Inventory");
    client.Load(piList);
    query.ViewXml = "<View/>";
    ListItemCollection collection = pmList.GetItems(query);
    client.Load(collection);
    client.ExecuteQuery();
    int prodid=0;
    foreach (ListItem item in collection)
    if (Convert.ToString(item["Product_x0020_Number"]) == ProductNumber)
    { prodid = Convert.ToInt32(item["ID"]); }
    ListItem piItem = piList.AddItem(new ListItemCreationInformation());
    piItem["Product_x0020_Number"] = new FieldLookupValue() { LookupId = prodid };
    piItem.Update();
    client.ExecuteQuery();
    Exception Detail
    Microsoft.SharePoint.Client.ServerException was caught
    Message=Invalid data has been used to update the list item. The field you are trying to update may be read only.
    Source=Microsoft.SharePoint.Client.Runtime
    ServerErrorCode=-2147352571
    ServerErrorTypeName=Microsoft.SharePoint.SPException
    ServerStackTrace=""
    StackTrace:
    at Microsoft.SharePoint.Client.ClientRequest.ProcessResponseStream(Stream responseStream)
    at Microsoft.SharePoint.Client.ClientRequest.ProcessResponse()
    at WebServiceProviders.ClientServices.NewProductInventory() in Z:\.............ClientServices.cs:line 889
    InnerException:
    Quick response is highly appreciated.
    Thanks
    Mehar

    Try some thing like below,
    your data value that needs to be update should be in this format "ID of the lookup";#"Title of the Lookup" 
    For example,
    listItem["Product_x0020_Number"]
    = "1;#iPhone";
    listItem["Product_x0020_Number"]
    = "2;#Mobile";
    Hope this helped you....

  • Fbl1n txn for updating vendor line item

    hello every one iam trying to update vendor line item when a billing document get cancelled in vf11 i have tried bapi  BAPI_ACC_DOCUMENT_REV_POST .
    the requirement is whenever a billing document get cancelled the commision need to get credited again for example if vendor line item is
         St Assignment         DocumentNo Type     Doc. Date  S DD Amount in local cur. LCurr Clrng doc. Text
            COMMISSION         1700000014 CP       31.08.2011                    71.26- INR
    it need to get like this
         St Assignment         DocumentNo Type     Doc. Date  S DD Amount in local cur. LCurr Clrng doc. Text
            COMMISSION         1700000014 CP       31.08.2011                    71.26 INR
    that means the amount in local currency need to get into + one like above
    Please help ASAP & if some one give me code also that will be very helpul for me

    Hii ali this is my code & below iam showing u what wasthe data in  my return table please suggest me what to do
          DATA : P_REVERSAL     LIKE  BAPIACREV ,
                 TRAN_DOC(20)   TYPE  C         ,
                 p_busact       LIKE BAPIACHE09-BUS_ACT ,
                 p_objkey       LIKE BAPIACREV-OBJ_KEY  .
          DATA : P_RETURN  LIKE  TABLE OF  BAPIRET2  ,
                 WA_RETURN  TYPE  BAPIRET2          ,
                 WF_REMARKS  ,
                 PLANT     TYPE VBRP-WERKS         ,
                 bill_no   type vbrk-vbeln         ,
                 belnr     type BELNR_D  ,
                 AWKEY     type AWKEY    .
    data : date1 type sy-datum .
    date1 = sy-datum+0(4) .
    select single belnr AWKEY from bkpf into (belnr , AWKEY)    where blart = 'CP'     and
                                                     budat = sy-datum and
                                                     xblnr = vbrk-kidno . "bill_no .
          IF SY-SUBRC = 0 .
              CONCATENATE belnr AWKEY+10(4) date1 INTO TRAN_DOC .
            ENDIF .
      SELECT SINGLE WERKS  FROM VBRP INTO  PLANT  WHERE VBELN = vbrk-kidno .
            p_reversal-obj_type   = 'BKPFF'.
            p_reversal-obj_key    = tran_doc.
            p_reversal-obj_key_r  = tran_doc.
            p_reversal-pstng_date = sy-datum.
            p_reversal-comp_code  = tran_doc+10(4).
            p_reversal-reason_rev = '02'.
            p_reversal-ac_doc_no  = tran_doc+0(10).
            p_busact = ' '.
            CALL FUNCTION 'BAPI_ACC_DOCUMENT_REV_POST'
            EXPORTING
              reversal = p_reversal
              bus_act  = p_busact
            IMPORTING
              obj_key  = p_objkey
            TABLES
              return   = p_return.
                  IF sy-subrc = 0.
                ---commit Work
                        CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
                          EXPORTING
                            wait = 'X'.
                  ELSE .
    *****Use the below statement, if the BAPI is sending back the 'RETURN' internal table.
                    READ TABLE p_return INTO WA_RETURN WITH KEY TYPE = 'F'.
                       IF SY-SUBRC EQ 0 .
                           CALL FUNCTION 'MESSAGE_TEXT_BUILD'
                          EXPORTING
                            MSGID = WA_RETURN-ID
                             MSGNR = WA_RETURN-NUMBER
                            MSGV1 = WA_RETURN-MESSAGE_V1
                             MSGV2 = WA_RETURN-MESSAGE_V2
                            MSGV3 = WA_RETURN-MESSAGE_V3
                            MSGV4 = WA_RETURN-MESSAGE_V4
                          IMPORTING
                            MESSAGE_TEXT_OUTPUT = WF_REMARKS.
                       ENDIF.
                    ENDIF.
    1     E     RW     609     Error in document: BKPFF $ DEVCLNT300          000000     BKPFF     $
    2     E     RW     632     Document BKPFF 1700000061WPL12011 DEVCLNT300 cannot be reversed          000000     BKPFF     1700000061WPL12011
    3     E     F5     814     Document type ZX not defined          000000     ZX
    4     E     F5     814     Document type ZX not defined          000000     ZX

  • BADI to modify the line items display in MIRO screen.

    Hello All,
    I am looking for a BADI to make some changes in the MIRO transaction.
    I am looking for following changes there:
    After entering the amount and the other details in MIRO screen if we press 'Simulate' button, we get the tax, amount and other details in a pop-up screen.
    I want to change the line items in the popup screen and add 1 more line item to it.
    I found out a BADI "INVOICE_UPDATE" for the same but i am not sure how far it will be of use in this regard.
    Moreover there are no export parameters in this BADI, so will it make any modifications in the pop-up screen?
    Could one of you please give me the answers to following questions in regard to above description:-
    1) Suggestions to make carry forward the above mentioned changes
    2) How to make sure if the BADI 'INVOICE_UPDATE' is apt for above scenario or not
    3) How to start with the implementations for the same if this BADI is the apt for the required changes
    Regards,
    Akanksha

    Hi,
    Try
    Exit: LMR1M001   -         User exits in Logistics Invoice Verification
    BADI or Enhancement Spot- INVOICE_UPDATE
    Use Method CHANGE_BEFORE_UPDATE -     Invoice Document Before Update
    Refer Link:[INVOICE_UPDATE|Regarding BADI , INVOICE_UPDATE ( MIRO transaction );

  • FF7B - Cash management Profit centre in the line item

    Hi,
    We are facing one problem at our end.
    We have upgraded our system to ECC 6 with new gl activated.
    Also activation of cash management (lequidity forecast) exist since 4.6C .
    Now with New GL activation in place and When we run FF7B -  ( Transaction to check the lequidity forecast ) it shows the summary details but when we drill-down to a line item level and copy profit centre as well as segment field from the layout for the line items the fields are appearing blank.
    Is anybody have the idea how to populate or update the profit centre as well as segement field in the same line item data in future and also for the past data.
    Thanks & Regards
    Mahesh

    this is available in Enhancement Pack 5.

  • BDC recording(updating two line items in a single call)

    Hi,
    I have a problem with the transaction PK31,while recording we enterd material number,plant,supply area in the first screen,after that it display line items for that control cycle,I want to update some fields in that line items,when i updated quantity and status fields in the first line item after that i cliked the change "qty/status button" and it saves that field values and it comes out from the transaction.
    can you please suggest what is the solution for updating two line items in a single call(PK31 transaction).

    Hi,
    In one screen . Put 2 containers with different names.
    cont1,cont2
    on each of the container call grid,grid1 like below .
    1. this is for item line display
    IF g_r_grid IS INITIAL.
          CREATE  OBJECT  g_r_cont
                      EXPORTING  container_name  =  'CONT1'.
        g_r_variant  =  sy-repid.
    *--Build  field  catalog
        PERFORM build_field_catalog.
    *--Layout selection
        g_r_layo-cwidth_opt  = g_c_set.
        g_r_layo-no_rowmark  = g_c_set.
        g_r_layo-sel_mode    = space.
        CALL METHOD g_r_grid->set_table_for_first_display
          EXPORTING
            i_buffer_active = g_c_set
            is_variant      = g_r_variant
            is_layout       = g_r_layo
            i_save          = g_c_set
            i_default       = g_c_set
          CHANGING
            it_outtab       = g_t_alv
            it_fieldcatalog = g_t_fieldcat
            it_sort         = g_t_sort.
      endif
    1. this is for error data display
    IF g_r_grid1 IS INITIAL.
          CREATE  OBJECT  g_r_cont
                      EXPORTING  container_name  =  'CONT2'.
        g_r_variant  =  sy-repid.
    *--Build  field  catalog
        PERFORM build_field_catalog.
    *--Layout selection
        g_r_layo-cwidth_opt  = g_c_set.
        g_r_layo-no_rowmark  = g_c_set.
        g_r_layo-sel_mode    = space.
        CALL METHOD g_r_grid->set_table_for_first_display
          EXPORTING
            i_buffer_active = g_c_set
            is_variant      = g_r_variant
            is_layout       = g_r_layo
            i_save          = g_c_set
            i_default       = g_c_set
          CHANGING
            it_outtab       = g_t_error
            it_fieldcatalog = g_t_fieldcat
            it_sort         = g_t_sort.
      endif

  • How to Reject Quotation line item and update New line item

    Hi all,
    I have a doubt in Quotation Rejection,Here it goes....
    For VC implementation,We are Creating a quotation with Dummy Material,and after Creating Material Masters we have to update the Newly created material back in Quotation for same quotation number and after this the dummy material i.e the previous line item should be rejected with reason as a duplicate(reason code 23)..
    So Pls help me in Rejecting the line item of quotation.how this is done.
    Reply soon.
    Thanks in Advance,
    Balaji Meda

    Hi,
    The requirement is also to Update the Quotation with the newly created material.
    So we need a Bapi or a function module which does 2 things:
    1. Reject the previous Line item with a reason code.
    2. Update the Quoation with the new material and insert a a new line item.
    Thanks,
    Balaji.

  • How to add the line items while running the VA01

    HI All,
    I want to add the line items while I am running the VA01 t-code(In run time).Could anybody give the FM to create the line items....Its urgent

    Hi ,
    User Exits In Sales Document Processing
    This IMG step describes additional installation-specific processing in sales document processing. In particular, the required INCLUDES and user exits are described.
    Involved program components
    System modifications for sales document processing affect different areas. Depending on the modification, you make the changes in the program components provided:
    MV45ATZZ
    For entering metadata for sales document processing. User-specific metadata must start with "ZZ".
    MV45AOZZ
    For entering additional installation-specific modules for sales document processing which are called up by the screen and run under PBO (Process Before Output) prior to output of the screen. The modules must start with "ZZ".
    MV45AIZZ
    For entering additional installation-specific modules for sales document processing. These are called up by the screen and run under PAI (Process After Input) after data input (for example, data validation). The modules must start with "ZZ".
    MV45AFZZ and MV45EFZ1
    For entering installation-specific FORM routines and for using user exits, which may be required and can be used if necessary. These program components are called up by the modules in MV45AOZZ or MV45AIZZ.
    User exits in the program MV45AFZZ
    The user exits which you can use for modifications in sales document processing are listed below.
    USEREXIT_DELETE_DOCUMENT
    This user exit can be used for deleting data which was stored in a separate table during sales document creation, for example, if the sales document is deleted.
    For example, if an additional table is filled with the name of the person in charge (ERNAM) during order entry, this data can also be deleted after the sales order has been deleted.
    The user exit is called up at the end of the FORM routine BELEG_LOESCHEN shortly before the routine BELEG_SICHERN.
    USEREXIT_FIELD_MODIFICATION
    This user exit can be used to modify the attributes of the screen fields.
    To do this, the screen fields are allocated to so-called modification groups 1 - 4 and can be edited together during a modification in ABAP. If a field has no field name, it cannot be allocated to a group.
    The usage of the field groups (modification group 1-4) is as follows:
    Modification group 1: Automatic modification with transaction MFAW
    Modification group 2: It contains 'LOO' for step loop fields
    Modification group 3: For modifications which depend on check tables or on other fixed information
    Modification group 4: is not used
    The FORM routine is called up for every field of a screen. If you require changes to be made, you must make them in this user exit.
    This FORM routine is called up by the module FELDAUSWAHL.
    See the Screen Painter manual for further information on structuring the interface.
    USEREXIT_MOVE_FIELD_TO_VBAK
    Use this user exit to assign values to new fields at sales document header level. It is described in the section "Transfer of the customer master fields into the sales document".
    The user exit is called up at the end of the FORM routine VBAK_FUELLEN.
    USEREXIT_MOVE_FIELD_TO_VBAP
    Use this user exit to assign values to new fields at sales document item level. It is described in the section "Copy customer master fields into the sales document".
    The user exit is called up at the end of the FORM routine VBAP_FUELLEN.
    USEREXIT_MOVE_FIELD_TO_VBEP
    Use this user exit to assign values to new fields at the level of the sales document schedule lines.
    The user exit is called up at the end of the FORM routine VBEP_FUELLEN.
    USEREXIT_MOVE_FIELD_TO_VBKD
    Use this user exit to assign values to new fields for business data of the sales document. It is described in the section "Copy customer master fields into sales document".
    The user exit is called up at the end of the FORM routine VBKD_FUELLEN.
    USEREXIT_NUMBER_RANGE
    Use this user exit to define the number ranges for internal document number assignment depending on the required fields. For example, if you want to define the number range depending on the sales organization (VKORG) or on the selling company (VKBUR), use this user exit.
    The user exit is called up in the FORM routine BELEG_SICHERN.
    USEREXIT_PRICING_PREPARE_TKOMK
    Use this user exit if you want to include and assign a value to an additional header field in the communication structure KOMK taken as a basis for pricing.
    USEREXIT_PRICING_PREPARE_TKOMP
    Use this user exit if you want to include or assign a value to an additional item field in the communication structure KOMP taken as a basis for pricing.
    USEREXIT_READ_DOCUMENT
    You use this user exit if further additional tables are to be read when importing TA01 or TA02.
    The user exit is called up at the end of the FORM routine BELEG_LESEN.
    USEREXIT_SAVE_DOCUMENT
    Use this user exit to fill user-specific statistics update tables.
    The user exit is called up by the FORM routine BELEG-SICHERN before the COMMIT command.
    Note
    If a standard field is changed, the field r185d-dataloss is set to X. The system queries this indicator at the beginning of the safety routine. This is why this indicator must also be set during the maintenance of user-specific tables that are also to be saved.
    USEREXIT_SAVE_DOCUMENT_PREPARE
    Use this user exit to make certain changes or checks immediately before saving a document. It is the last possibility for changing or checking a document before posting.
    The user exit is carried out at the beginning of the FORM routine BELEG_SICHERN.
    User exits in the program MV45AFZA
    USEREXIT_MOVE_FIELD_TO_KOMKD
    Use this user exit to include or assign values to additional header fields in the communication structure KOMKD taken as a basis for the material determination. This is described in detail in the section "New fields for material determination".
    USEREXIT_MOVE_FIELD_TO_KOMPD
    Use this user exit to include or assign values to additional item fields in the communication structure KOMPD taken as a basis for the material determination. This is described in detail in the section "New fields for material determination".
    USEREXIT_MOVE_FIELD_TO_KOMKG
    Use this user exit to include or assign values to additional fields in the communication structure KOMKG taken as a basis for material determination and material listing. This is described in detail in the section "New fields for listing/exclusion".
    USEREXIT_MOVE_FIELD_TO_KOMPG
    Use this user exit to include or assign values to additional fields in the communication structure KOMPG taken as a basis for material determination and material listung. This is described in detail in the section "New fields for listing/exclusion".
    USEREXIT_REFRESH_DOCUMENT
    With this user exit, you can reset certain customer-specific fields as soon as processing of a sales document is finished and before the following document is edited.
    For example, if the credit limit of the sold-to party is read during document processing, in each case it must be reset again before processing the next document so that the credit limit is not used for the sold-to party of the following document.
    The user exit is executed when a document is saved if you leave the processing of a document with F3 or F15.
    The user exit is called up at the end of the FORM routine BELEG_INITIALISIEREN.
    User-Exits in program MV45AFZB
    USEREXIT_CHECK_XVBAP_FOR_DELET
    In this user exit, you can enter additional data for deletion of an item. If the criteria are met, the item is not deleted (unlike in the standard system).
    USEREXIT_CHECK_XVBEP_FOR_DELET
    In this user exit, you can enter additional data for deletion of a schedule line. If the criteria are met, the schedule line is not deleted (unlike in the standard system).
    USEREXIT_CHECK_VBAK
    This user exit can be used to carry out additional checks (e.g. for completion) in the document header. The system could, for example, check whether certain shipping conditions are allowed for a particular customer group.
    USEREXIT_CHECK_VBAP
    This user exit can be used to carry out additional checks (e.g. for completion) at item level.
    USEREXIT_CHECK_VBKD
    The user exit can be used to carry out additional checks (e.g. for completion) on the business data in the order.
    USEREXIT_CHECK_VBEP
    This user exit can be use to carry out additional checks (e.g. for completion) on the schedule line. During BOM explosion, for example, you may want certain fields to be copied from the main item to the sub-items (as for billing block in the standard system).
    USEREXIT_CHECK_VBSN
    You can use this user exit to carry out additional checks (e.g. for completion) on the serial number.
    USEREXIT_CHECK_XVBSN_FOR_DELET In this user exit, you can enter additional criteria for deletion of the serial number. If the criteria are met, the serial number is not deleted (unlike in the standard system).
    USEREXIT_FILL_VBAP_FROM_HVBAP
    You can use this user exit to fill additional fields in the sub-item with data from the main item.
    USEREXIT_MOVE_FIELD_TO_TVCOM_H
    You can use this user exit to influence text determination for header texts. For example, you can include new fields for text determination or fill fields that already exist with a new value.
    USEREXIT_MOVE_FIELD_TO_TVCOM_I
    You can use this user exit to influence text determination for item texts. For example, you can include new fields for text determination or fill fields that already exist with a new value.
    User-Exits for product allocation:
    The following user exits all apply to structure COBL, in which the data for account determination is copied to item level.
    USEREXIT_MOVE_FIELD_TO_COBL
    Option to include new fields in structure COBL.
    USEREXIT_COBL_RECEIVE_VBAK
    Option to assign values from the document header to the new fields.
    USEREXIT_COBL_RECEIVE_VBAP
    Option to supply values from the item to the new fields.
    USEREXIT_COBL_SEND_ITEM
    A changed field can be copied from the structure into the item. You could use the user exit to display a certain field in the account assignment block (see also MV45AFZB).
    USEREXIT_COBL_SEND_HEADER
    A changed field can be copied from the structure to the header (see source text MV45AFZB)
    USEREXIT_SOURCE_DETERMINATION
    You can use this user exit to determine which plant will be used for the delivery. In the standard system, the delivering plant is copied from the customer master or the customer-material info record. If you want to use a different rule, then you must enter it in this user exit.
    USEREXIT_MOVE_FIELD_TO_ME_REQ
    With this user exit you can include additional fields for the following fields:
    EBAN (purchase requisition)
    EBKN (purchase requisition-account assignment)
    USEREXIT_GET_FIELD_FROM_SDCOM
    Option to include new fields for the variant configuration. Fields that are included in structure SDCOM can be processed and then returned to the order.
    USEREXIT_MOVE_WORKAREA_TO_SDWA
    You can use this user exit to format additional work areas for the variant configuration. You will find notes on the user exit in MV45AFZB.
    User-Exits for first data transfer:
    The following user exits can only be used for the first data transfer.
    Note
    Only use the user exits if the names/fields do NOT have the same name.
    USEREXIT_MOVE_FIELD_TO_VBAKKOM
    Option to include additional fields in structure VBAKKOM (communiction fields for maintaining the sales document header)
    USEREXIT_MOVE_FIELD_TO_VBAPKOM
    Option to include additional fields in structure VBAPKOM (communication fields for maintaining a sales item)
    USEREXIT_MOVE_FIELD_TO_VBEPKOM
    Option to include additional fields in structure VBEPKOM (communication fields for maintaining a sales document schedule line)
    USEREXIT_MOVE_FIELD_TO_VBSN
    You can use this user exit to include fields in structure VBSN (scheduling agreement-related change status).
    USEREXIT_MOVE_FIELD_TO_KOMKH
    You can use this user exit to include new fields for batch determination (document header).
    USEREXIT_MOVE_FIELD_TO_KOMPH
    You can use this user exit to include new fields for batch determination (document item).
    USEREXIT_CUST_MATERIAL_READ
    You can use this user exit to set another customer number in the customer material info record (e.g. with a customer hierarchy)
    USEREXIT_NEW_PRICING_VBAP
    Option for entry of preconditions for carrying out pricing again (e.g. changes made to a certain item field could be used as the precondition for pricing to be carried out again). Further information in MV45AFZB.
    USEREXIT_NEW_PRICING_VBKD
    Option for entry of preconditions for carrying out pricing again (e.g. changes to the customer group or price group could be set as the preconditions for the system to carry out pricing again). Further information in MV45AFZB.
    User-Exits in Program MV45AFZD
    USEREXIT_CONFIG_DATE_EXPLOSION
    The BOM is exploded in the order with the entry date. You can use this user exit to determine which data should be used to explode the BOM (explosion with required delivery date, for example).
    User exits in the program FV45EFZ1
    USEREXIT_CHANGE_SALES_ORDER
    In the standard SAP R/3 System, the quantity and confirmed date of the sales document schedule line is changed automatically if a purchase requisition is allocated, and it or the sales document is changed (for example, quantity, date).
    If you want to change this configuration in the standard system, you can define certain requirements in order to protect your sales orders from being changed automatically. Use this user exit for this purpose. Decide at this point whether the schedule lines are to be changed.
    User-Exits in Program RV45PFZA
    USEREXIT_SET_STATUS_VBUK
    In this user exit you can you can store a specification for the reserve fields in VBUK (header status). Reserve field UVK01 could, for example, be used for an additional order status (as for rejections status, etc.).
    The following workareas are available for this user exit:
    VBUK (header status)
    FXVBUP (item status)
    FXVBUV (Incompletion)
    USEREXIT_SET_STATUS_VBUP
    In this user exit you can you can store a specification for the reserve fields for VBUP (item status).
    The following workareas are available for this user exit:
    FXVBAP (Item data)
    FXVBAPF (Dynamic part of order item flow)
    FXVBUV (Incompletion)
    USEREXIT_STATUS_VBUK_INVOICE
    You can use this user exit to influence billing status at header level.
    User exits in the screens
    Additional header data is on screen SAPMV45A 0309, additional item data on screen SAPMV45A 0459. These screens contain the Include screens SAPMV45A 8309 or SAPMV45A 8459 as user exits.
    Fields which are also to be included in the sales document for a specific installation should be included on the Include screens for maintaining. If an application-specific check module is needed for the fields, this can be included in the Include MV45AIZZ. The module is called up in the processing logic of the Include screens.
    For field transports, you do not have to make changes or adjustments.
    Example
    A new field, VBAK-ZZKUN, should be included in table VBAK.
    If the check is defined via the Dictionary (fixed values or check table) the field must be included with the fullscreen editor in the Include screen SAPMV45A 8309. In this case, no change has to be made to the processing logic.
    User Exits in Program MV45AFZ4
    USEREXIT_MOVE_FIELD_TO_KOMK
    You can use this user exit to add or edit additional header fields in the communication structure - KOMK- for free goods determination. For more information, see the New Fields for Free Goods Determination IMG activity.
    USEREXIT_MOVE_FIELD_TO_KOMP
    You can use this user exit to add or edit additional item fields in the communication structure KOMP for free goods determination. For more information see the New Fields for Free Goods Determination IMG activity.
    User Exits in the SAPFV45PF0E and SAPFV45PF0C Programs
    EXIT_SAPFV45P_001
    You can use this user exit to decide whether intercompany billing data is used in the profitability segment for cross-company code sales, or whether the data comes from external billing (external customer, sales data from the selling company code.
    regards
    P.

  • SAPF150D-Dunning Notice Print - With Update of Line Items and Master Record

    When I am running this program SAPF150D(Dunning Notice Print - With Update of Line Items and Master Records) with a variant containing run date, runc id, update mode, pimmed & pcount; the job is failing to execute. It is giving message like,
    "The field symbol is no longer assigned because there was an attempt makde previously in a Unicode program to set the field symbol using ASSIGN with offset and/or length specification. Here, the memory addressed by the offset/length specification was not within the allowed area."
    "GETWA_NOT_ASSIGNED_RANGE" "SAPF150D" or "F150DFS0" "SORTFELDER_ERMITTELN"

    Hi,
    Search for routine FORM SORTFELDER_ERMITTELN
    in SAPF150D.
    Put a breakpoint in statement
    ASSIGN (T047F-FELDN) TO <H1>.
    in above routine and debug to the point where error is occuring.
    Most likely there is a mismatch in the length assigned to some field FELDN in table T047F.
    In that case, simply change the T047F-LENGT field accordingly in change mode.
    Cheers,
    Vikram
    Edited by: Vikram Jalali on May 27, 2008 5:56 PM

  • Make changes to the line item depending upon doc type n sp. GL ind in F-48

    I want to make changes to the line item depending upon the document type and special GL indication for the transaction code F-48.
    Depending upon document type and special GL indicator i want to calculate the work contract tax during simulation in transaction code F-48.

    Hi,
    You want to deduct WCT when you use particular document type and special gl indicator.
    I just want to know the reason why you want to determine the WCT based on the above conditions.
    I created WCT as withholding tax types and assigned to vendor master. So when the user booking transactions he will choose the respective WCT tax type and tax code so system will deduct the amount and the same updated in WITH_ITEM.
    Or you made a down payment request through T.code F-47 and when you want to book the actual transaction in F-48 then choose line item from down payment request.
    Give me your requirement in clear if the above is not clear
    Regards,
    Sankar

  • Function module for BOM Update all line items at a time

    Hi,
    Please enlightenn us, which FM is do the update for BOM item datas. ( current FM is updated line item one item then come out and log in again updating another line item , thus cause more error are facing.)
    we want a FM to update one time all the line time and come out from the screen.
    Thx
    Sathiya

    HI,
    As suggested above use CEWB or if you want to manage it via a Z program then use:
    CSAP_MAT_BOM_MAINTAIN
    or
    CSAP_MAT_BOM_OPEN
    CSAP_BOM_ITEM_MAINTAIN (Use these 3 in sequence, refer to the help file on the FM)
    CSAP_MAT_BOM_CLOSE
    Hope it answers your query.
    Regards,
    Vivek

  • How do we update the existing item in Cache (RWB) without know GUID?

    Hi Friends,
        We want to update the existing item in Cache (Value Mapping). Assume that Cache Contains like
         IN --> INDIA
         FR --> FRANCE
         EN --> ENGLAND
        We want to change ENGLAND to LONDON. How it is possible ... ? (Assume that above mapping data is replicated from my text file/Oracle Table, already).
    Kindly reply.
    Kind Regards,
    Jegatheeswaran P.

    Hi Vijay,
        Whatever the value mapping table we created in Intergration Directory, we can display & edit values of particular item. Because, they are stored in the XI default context 'http://sap.com/xi/XI'. In this case, it is not necessary to know the context and GUID value.
        But, in my case, I have replicated value mapping data from external system (SAP table/Text File/Oracle Table) into RWB --> Cache Monitoring --> Runtime Cache. I use my own context like 'http://aprilbiztec.com/FRAMEWORK/FileToFile'. In this case, how do we edit the particular line item. This is my problem.
    Kindly help me.
    Thanks in advance.

  • How to submit  the values in the ztable to the line items

    Hi everybody
    Please give me the code to my task
      I am having a Z Table with one field and with some certain records  and  i am having an unique value .
    This unique value should be submitted in all  the line items which are having the
    Z table records.
    Please help me and thanks in advance

    Please provide the details of your requirement. Its not very clear.

Maybe you are looking for