Prevent identical Sales Site and Sold-to BP Number

SOLVED

Good afternoon, we'd like to prevent our various sales sites from accidentally creating sales orders with identical Sales and Ship-to sites. Currently, there is a warning pop-up, but it does not fully stop the transaction, it just warns the user as soon as it detects identical values. It looks like this:

However, we would rather have this as pop-up that just prevents this action in the first place.

Any thoughts?

Thanks

Zoey

Top Replies

Parents
  • 0

    Unfortunately I am still searching for a solution to this. Does anyone have any insight?

  • 0 in reply to Zoey Mattison

    Hi 
    Before suggesting anything, I want to clarify your request: you want to forbid the sales site entered in the header of the sales order is the same than the Ship site entered in the line.

    Is it right?

  • 0 in reply to Julien Patureau

    thanks for getting back to me! Let me clarify. I have updated the title to reflect this post a little better. Sorry for not being clear before --

    I am trying to prevent the fields SALFCY and BPCORD from being identical in the sales order header (SOH0), either by actively checking for this or by preventing the document from being created.

    Currently, in one of the standard scripts (maybe SUBSOHA) there is some code that returns this dialogue box if you enter identical values into those fields: (the message is 151,191,1)

    This is a good measure, but unfortunately it allows you to continue on with the creation of the document by clicking OK. Normally this wouldn't be a problem.. However, we have a process where we require our retail stores to send product back to the warehouse for various reasons. I will spare the details, but basically they will create a sales order using their site as the sales site (eg. 2600) and the sold-to customer number should be the warehouse (IDC30). However, even with this pop-up they manage to re-enter their own site into the sold-to customer number, as shown above. I am just looking to prevent this outright instead of just warning about it.

    I would prefer not to modify any SPE files if possible, and instead stop the creation of the document when the user clicks "create" with a custom script, like by setting an action to run under the predefined create button in the OSOH window as shown here. I'm not sure of the context for these buttons, but I read somewhere that they pass an "OK" value, and setting it to 0 will stop the creation. I do not know enough to try it out at this time though (don't want to mess anything up with a bad script):

    I will take anything you want to share regarding this. Thank you again for replying.

    Zoey

Reply
  • 0 in reply to Julien Patureau

    thanks for getting back to me! Let me clarify. I have updated the title to reflect this post a little better. Sorry for not being clear before --

    I am trying to prevent the fields SALFCY and BPCORD from being identical in the sales order header (SOH0), either by actively checking for this or by preventing the document from being created.

    Currently, in one of the standard scripts (maybe SUBSOHA) there is some code that returns this dialogue box if you enter identical values into those fields: (the message is 151,191,1)

    This is a good measure, but unfortunately it allows you to continue on with the creation of the document by clicking OK. Normally this wouldn't be a problem.. However, we have a process where we require our retail stores to send product back to the warehouse for various reasons. I will spare the details, but basically they will create a sales order using their site as the sales site (eg. 2600) and the sold-to customer number should be the warehouse (IDC30). However, even with this pop-up they manage to re-enter their own site into the sold-to customer number, as shown above. I am just looking to prevent this outright instead of just warning about it.

    I would prefer not to modify any SPE files if possible, and instead stop the creation of the document when the user clicks "create" with a custom script, like by setting an action to run under the predefined create button in the OSOH window as shown here. I'm not sure of the context for these buttons, but I read somewhere that they pass an "OK" value, and setting it to 0 will stop the creation. I do not know enough to try it out at this time though (don't want to mess anything up with a bad script):

    I will take anything you want to share regarding this. Thank you again for replying.

    Zoey

Children