Skip to Content
avatar image
Former Member

Sales order mass change

Hi,

There is a custom report - sales order mass change cockpit, when executed it will display sales order details with item , header and BOM components.And also there are customized button to change Requested Delivery date, Delivery block, Reasons for rejection.

In this report i need to do modifications like -

- It should not be possible to change the data in BOM components because they are not delivered separately, only the BOM header is being removed from the stock at goods issue. Therefore:

1. If in the selection screen u201CDisplay BOM componentsu201D is not set, donu2019t include in the report output the order items with both VBAP-UEPOS and VBAP-STLNR not equal to zero

2. If u201CDisplay BOM componentsu201D is set, show the records with VBAP-UEPOS and VBAP-STLNR not equal to zero but donu2019t allow them to be selected for mass-changes (no button to be pressed available). The modifications done at BOM header will be copied into the components automatically by SAP standard.

Pls. help me how to put the code and where.

Let me know any further clarification needed.

Thanks.

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Jun 23, 2010 at 09:43 AM

    Hi,

    Suppose you have Displa BOM Component as checkbox : ch

    For

    1. If in the selection screen u201CDisplay BOM componentsu201D is not set, donu2019t include in the report output the order items with both VBAP-UEPOS and VBAP-STLNR not equal to zero

    if ch <> 'X'.

    delete the items whose VBAP-UEPOS <> 0 and VBAP-STLNR <> 0

    delete form itab_item where VBAP-UEPOS <> 0 and VBAP-STLNR.

    ENDIF.

    2. If u201CDisplay BOM componentsu201D is set, show the records with VBAP-UEPOS and VBAP-STLNR not equal to zero but donu2019t allow them to be selected for mass-changes (no button to be pressed available). The modifications done at BOM header will be copied into the components automatically by SAP standard.

    if ch = 'X'.

    loop at item_itab

    if wa_item-UEPOS is not initial and/or wa_item-STLNR is not initial.

    set a wa_item-flag = 'N'.

    endif.

    append wa to final_item.

    endloop.

    I hope it answers your query.

    Regards,

    Uma Dave

    Add comment
    10|10000 characters needed characters exceeded