Opportunities - Delete item before save - BADI

I need to do some checks when adding a new item in an opportunity and depending on these checks, this item must be removed before save.
I tried in the BADI's ORDER_SAVE and CRM_ORDERADM_I_BADI, using several function modules like: CRM_ORDER_MAINTAIN,  CRM_ORDERADM_I_DELETE_OB, ... but all without result. Using the xxx_OB function modules in the CRM_ORDERADM_I_BADI resulted always in shortdump after the BADI processing.
Anyone who had to do something similar?
Thanks a lot!

Hi Filip,
I need to understand better what sort of checks would you like to carry out
<b><u>In my case I needed to cover or block a field in a crm order item, if the status of invoice in status tab at header level, was  "invoice issued".</u></b>
I used CRM_ORDER_FIELDCHECK as Badi definition.
I define the code in this way, overwriting the method FIELDCHECK with abap code just to block the field quantity at the item level, as said:
Code structure:
1 tables  and structures for CRM_ORDER_READ;
2 Definition memory parameters
  3 Selection document item by using CRMD_ORDERADM_I to get item-guid
    4 Selection doc number, by usign item-guid
       5  call of  funcition module 'CRM_ORDER_CHANGE_STATUS_GET'
         6 Status check and field quantity blocked (grey colour = A), if status is equal C.
If you need to change an existing document I suggest using,  as said in the forum, <b><u>Crm_order_maintain, or better employing BAPI CHANGEMULTI</u>[/b<b><u>], which is using CRM_ORDER_MAINTAIN.</u></b>
I suggest using Bapi 'cause it 's easier to manage, especially concerning Internal tables.
I had to change Price condition in my CRM ORDERS, when I used such bapi and/or FM crm_order_maintain.
Just let me know your changes better.
Please rewards with points if it helps,
AndreA

Similar Messages

  • Modify purchase order item before to save

    Hi all,
    I'm trying to modify EKPO-RETPO field from purchase order item before save it.
    I've done it in the user exit: EXIT_SAPMM06E_013, but I've seen it coudl be use for update customer fields.
    Anybody knows which user exit can I use to do that?
    Thanks in advance.
    Pat.

    Hello,
    You can use the BADI *MEPROCESS_PO_CUST* to suffice the requirement.
    In this structure IM_ITEM has field RETPO. Please pass value to it
    Hope this will help.
    Thanks
    Eswar

  • In microsoft office word, how do I delete items from the recent documents tableau? I have options for new, open, save, save as, etc. but no option to delete.

    In microsoft office word, how do I delete items from the recent documents tableau? I have options for new, open, save, saveas, etc. but no option to delete. Thank you.

    Hello.
    I have no idea and you should contact Microsoft for support. This is Firefox's support forum.
    Thank you for your understanding.

  • I need Badi for PO Before save.

    Hi Abappers,
    i want Badi name for PO Before save.
    Regards,
    vani.

    Hi,
    To find the badi for a particular transaction goto TCode SE24 and give the class name as CL_EXITHANDLER and then display it. now double-click on GET_INSTANCE you will get some source code , put a break point on class name and give TCode on command field then debug . double click on class name and go on pressing F5, you willl get list of BADI's and according to your requirement choose the right one.
    Second procedure:
    Go to SE84, Enhancements< Business-addin< definition(double click) and give package name of particular transaction then you will get BADI's. Read documentation by going to SE18 or SPRO and choose the right one according to your requirement
    I think ME_PROCESS_PO_CUST may satify your requirement.

  • Validate a page item before go to next item without press save or submit

    Hello,
    I will be very greatful if someone help me. using apex 3.1.2
    actaully, i have created a form and all work fine including validations and processess but i want to know how can i validate an item before submit the form?
    for example: if i have two items on the page i.e :p1_item1 and :p2_item2 and save button so i like to validate both items before press the save button?
    if item1 is date item then should check date is correct format before go to next item? at the moment i am validating when press save button and its work fine!
    thanks for help.
    kind regarrds,
    RI
    Edited by: Irha10 on 13-May-2011 15:40
    Edited by: Irha10 on 13-May-2011 16:45

    Hi,
    If it is related to date.. why don't you use jQuery Date picker and disable manual entry into the field...
    this will make sure that date is always in correct format...
    Anyways... You have the options to use Javascript function to validate that the date is in correct format by calling the function onblur..
    Regards,
    Shijesh

  • Is it possible to Delete items under the Save As button in BW Web Pages?

    Currently the ability to Delete items under the Save As button in BW Web Pages is not allowed. Is it an SAP supplied functionality?
    Do you khow how this can be done? thanks in advance.

    Hi Lin,
    when you click save as button, it will save bookmarks in KM folders for BEx Portfolio, My Portfolio, My favorites
    you can delete items in corrosponding iViews, i.e. execute BEx portfolio iView and manage book marks
    srinivas

  • Need to save mails in Deleted Items on E72

    It is though Ovi mail has gone beserk, sending me messages I have already deleted. So I need to empty my intray online and on the two E72s I am using.
    But before I delete all, I have found some delted messages I want to keep, but can't find a way to move them - only option seems to be to empty the Deleted Items tray.
    Any ideas?
    hughm_nyksj_dk

    Since FL Studio is not an Apple product, post your question their own discusion forums:  http://forum.image-line.com/

  • I bought a used ipod touch that had 2200 bad songs.  Unfortunately I decided to try to delete them before I started buying music.  It deleted EVERYTHING.  Help!!  I'm looking at a screen that says itunes and nothing else.

    I bought a used ipod touch that had 2200 bad songs.  Unfortunately I decided to delete them before I started purchasing music.  EVERYTHING was deleted.  The screen is blank except for the itunes emblem.  Help!

    First, try a system reset.  It cures many ills and it's quick, easy and harmless...
    Hold down the on/off switch and the Home button simultaneously until the screen blacks out or you see the Apple logo.  Ignore the "Slide to power off" text if it appears.  You will not lose any apps, data, music, movies, settings, etc.
    If the Reset doesn't work, try a Restore.  Note that it's nowhere near as quick as a Reset.  From iTunes, select the iPad/iPod and then select the Summary tab.

  • Badi PO before save

    does anyone know any badi for PO before save?
    i need validation to popup a message before save.

    Hi Oscar,
    I have quickly gone through the documentation, but I guess ME_PROCESS_PO_CUST is the one to use (this one is meant for customer enhancements). Also take a look into the documentation of Interface IF_EX_ME_PROCESS_PO_CUST.
    Probably method POST is called in update task, this is why your program will not stop at this point (unless you activate update-debugging).
    Regards,
    John.

  • Purchase order - error in deleted items

    Hi all,
    I have the following situation: when changing an existent purchase order, if I have a deleted item with an error, the system doesn't allow me to save the purchase order if I don't correct the error in the deleted item.
    I have a requirement for the client to suppress this behaviour.
    Any ideas on this?
    Thanks in advance.
    Best regards,
    Sónia Gonçalves

    Hi,
    First of all, thank you all for your answers.
    I got this from SAP:
    "As per system design, the PO item must be free of errors before you can save it (even if it is deleted). This is to ensure that no error appears suddenly if the PO item is later undeleted. SAP generally
    allows saving only if the entered data is consistent, so that it does not cause unexpected errors later"
    I have a requirement to suppress this behaviour, since the client doesn't understand why they have to correct a deleted item.
    Any ideas on a user-exit ou badi where I could ignore this validation and how?
    Thanks.
    Best regards,
    Sónia Gonçalves

  • Deleted items contain no message, or attachment, just the headers

    in my deleted items folder almost all the messages are blank except for the headers.
    How can I stop this happening?
    Can I get the messages back?
    Thanks.
    arkidenti

    It is likely that the PDFs you created did not have the fonts embedded and somehow the font recognition was changed. Anyway, you can likely select some text that needs to be fixed and right click for the properties. Then select the proper font and ask it to embed the font.
    Another option would be to save the PDF as a DOC file and work from there. Extra work, but might be faster and safer in the long run. Editing PDF files is not really good and may actually be more work than recreating the original DOC file. If you work with style sheets, the recreation might actually go fairly fast.
    As far as Acrobat and the problem, do you have a machine available with AA6 that you mentioned? If so, try it there too before you conclude you just need to back up.

  • How do I get my deleted emails to go to the deleted items in Outlook and not the archived folder?

    How do I get my deleted emails to go to the deleted items in Outlook and not the archived folder?

    Who is the email account provider?
    With an Apple iCloud account, there is a preference setting with the account settings on the iPhone to archive messages - save deleted messages in your Archive folder.
    I believe the same is available with a Gmail account.

  • Cannot delete items from ipod...recently installed 1.4.1 and itunes 7

    i just did the restart in 'services', and my ipod mini is now recognized in itunes 7. thanks to all who offered advice....especially ivan.
    hp pavillion ze1210
    windows xp
    ipod mini
    software 1.4.1 *
    itunes 7 *
    *itunes 7 and software 1.4.1 were both installed within the last 24 hours and the ipod mini is approx 2 years old
    i can add music and podcasts from my computer, but i cannot delete them from the ipod....i can delete items from specific playlists but not from the ipod itself.
    when my ipod is selected in itunes under devices, i get a main screen that has four options...
    summary
    music
    podcasts
    contacts
    when i select 'podcasts', it shows me the podcasts i subscribe to on the main screen, but i can't do anything ....they appear to be somewhat greyed out. the same is true with 'music' i can see the playlists on my ipod, but i can't manage them. however, i can delete anything from specific playlists on the left...but they remain on the ipod.
    how can i access the main middle screen to delete items from the ipod?
    before installing 7, if i selected my ipod in itunes, i could delete anything from the ipod itself...not just playlists.
    please help ASAP as i only have approx. 300 MB of space remaining.

    Click on the disclosure triangle in front of the iPod name.
    This will show you the contents of your iPod. Click on Music below the iPod name to see the songs on the iPod.

  • Deleted Items glitch?

    My incoming .mac mail is going to the Deleted Items box on my IMAP mail clients (both Mail program, and in Entourage). When I check my dot mac mail on the web, that same mail is in the Inbox.
    This is new behaviour, and I don't recall changing any settings. I have no rules in effect. I am used to checking the IMPAP Inbox for new items.
    How do I make new mail go in to my Inbox and not to Deleted Items?

    Even though you've said you have "no rules in effect", this looks like a rules issue to me, so try this to be sure (it could be that the rules file is corrupt, for example):
    1. Quit Mail.
    2. In the Finder, go to ~/Library/Mail/.
    3. Locate MessageRules.plist and move it to the Desktop. If there is a file called MessageRules.plist.backup, move it to the Desktop too. You may also see MessageSorting.plist files there; this is where Mail 1.x stored the rules, and they are no longer used by Mail 2.x, so just move them to the Trash if you see them.
    4. Open Mail. As a result of removing the rules file, the junk filter will be disabled now. You may want to either tell Mail to go offline immediately after opening it, or shut down the Internet connection before opening Mail, to prevent it from downloading anything until the junk mail filter has been enabled again.
    5. Go to Mail > Preferences > Junk Mail, enable junk filtering, and configure it however you wish.
    6. Go online again if you went offline in step 4.
    If the problem persists after doing this, then you know the rules have no bearing on it, and you may move the files on the Desktop back to the ~/Library/Mail/ folder, overwriting any files Mail may have created anew there (quit Mail first).
    Note: For those not familiarized with the ~/ notation, it refers to the user's home folder.

  • Recycle bin to show all deleted items on the site collection for specific user group

    hi there, is there any way where a certain sharepoint group (i.e. site collection members) to view and restore deleted items on theentire collection, without giving them site collection rights orgive them more rights than necessary? we wanted to create
    aSP group that has the permission to restore deleted items and give them to selected users so that our users won't have to contact us when they want to restore a deleted item

    I don't believe you can. If an item get's deleted it should go to the first recycle bin @ /_layouts/15/RecycleBin.aspx
    The Recycle Bin gives a site collection administrator
    greater control when users delete files, versions of files, list items, libraries, lists, and folders from a SharePoint site by providing a second stage safety net before an item is permanently deleted from a site. When a user deletes an item from the Recycle
    Bin, the item is sent to a second stage Recycle Bin (also known as the Site Collection Recycle Bin) that the site collection administrator manages. This article focuses on how a site collection administrator can manage the Recycle Bin for a site collection.
    https://support.office.com/en-US/Article/Manage-the-Recycle-Bin-of-a-SharePoint-site-collection-5fa924ee-16d7-487b-9a0a-021b9062d14b
    Ibrahim Sukari, Technical Consultant | SharePoint | Dynamics CRM |
    LinkedIn Profile

Maybe you are looking for