none
How to display "order number" as Pop-up message on save of the order form?

    Question

  • Hi All,

    On saving the order form "order number" should display as a pop-up message . I tried through alert in Jscript. But only after the alert call, the order number is generating.

    my requirement is i have to enter multiple order based on the hard copy i have. i will be mentioning the order number in respective hard copy. so if i give save &new or save & close, the order number should display before closing the form. 

    Any solutions ?

    Friday, December 30, 2011 8:37 AM

All replies

  • Hi,

    The order number is generated server side, so it is not available until the form closes - i.e. after the OnSave event. You cannot therefore display an alert() message in JavaScript in a supported fashion.

    Possibly you could write a post-update/create synchronous plugin that retreives the newly created order and throws an exception of type InvalidPluginException with a message including the order number. This message will be displayed to the user as an altert by CRM. It is however not a very nice way of providing feedback to the user, but it works.

    /Allan

     


    ----- Allan Varcoe, Cinteros AB, Stockholm, Sweden http://www.cinteros.se MCT, MBSP, MCTS, etc.
    Friday, December 30, 2011 11:10 AM
  • Hi ShankerBala

      I will agree with Allan , that plugin approach is not the best solutions

     Not used to display messages..

      The way I got implementing is

     Writing logic on  page Load , to display the order Number onces page is refreshed  after submitting the  newly created Order

    Hth

    dkay

     if the response answered your question, please take a minute and mark the response as an answer.

    Friday, December 30, 2011 12:58 PM
  • Hi,

    The problem - as far as I understand - is that the user will do Save&New or Save&Close. I.e. there will be no refresh of the saved page. Therefore it will not be possible to do OnLoad.

    /Allan

     


    ----- Allan Varcoe, Cinteros AB, Stockholm, Sweden http://www.cinteros.se MCT, MBSP, MCTS, etc.
    Friday, December 30, 2011 1:41 PM
  • Hi ,

     In that case , 

      When the Form is the CREATE Mode its can only Display SAVE button and hide the "SAVE & Close " and " SAVE & new " buttons

    Hth

    dkay

     if the response answered your question, please take a minute and mark the response as an answer

     

     

    Friday, December 30, 2011 2:33 PM