locked
Resolve case in MS CRM 2011 RRS feed

  • Question

  • I am working on CRM 2011, and i would like to know the following:

    When I click on 'Resolve a Case' button, I want one pop up to display where I can ask the user to enter something.. Is this possible??  

    Wednesday, June 22, 2011 9:22 AM

Answers

  • Hi Swesa,

    You can call the following script on Form OnSave event (Make sure to Check Pass Execution Context as first paramter option) to open pop up window before system displays "Resolve a Case" window.

    function FrmOnSave(prmContext) {
        var lclSaveMode;

        if (prmContext != null && prmContext.getEventArgs() != null) {

            lclSaveMode = prmContext.getEventArgs().getSaveMode();

            switch (lclSaveMode) {
                // On Event = Resolve Case                          
                case 5:
        // Your custom code will come here
                    window.returnValue = 1;
                    break;
               
            }
        }
    }

     

    I hope this solves your issue


    Jehanzeb Javeed

    http://worldofdynamics.blogspot.com
    Linked-In Profile |CodePlex Profile

    If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".

    Wednesday, June 22, 2011 1:53 PM

All replies

  •  

    I think writing a  plugin on "Close"  pre event will do the trick.

    I hope it helps.

     

     


    Amreek singh Senior CRM Consultant CDC Praxa Sydney, <href>Australia http://mscrmshop.blogspot.com<href>
    Wednesday, June 22, 2011 11:24 AM
  • Hi Swesa,

    You can call the following script on Form OnSave event (Make sure to Check Pass Execution Context as first paramter option) to open pop up window before system displays "Resolve a Case" window.

    function FrmOnSave(prmContext) {
        var lclSaveMode;

        if (prmContext != null && prmContext.getEventArgs() != null) {

            lclSaveMode = prmContext.getEventArgs().getSaveMode();

            switch (lclSaveMode) {
                // On Event = Resolve Case                          
                case 5:
        // Your custom code will come here
                    window.returnValue = 1;
                    break;
               
            }
        }
    }

     

    I hope this solves your issue


    Jehanzeb Javeed

    http://worldofdynamics.blogspot.com
    Linked-In Profile |CodePlex Profile

    If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".

    Wednesday, June 22, 2011 1:53 PM
  • You should be able to use a CloseIncidentRequest to do this.  You can access web services in Jscript also.  I recommend reviewing my blog linked in my signature to understand calling the web services from Jscript.

    http://msdn.microsoft.com/en-us/library/microsoft.crm.sdk.messages.closeincidentrequest.aspx


    Jamie Miley
    http://mileyja.blogspot.com
    Linked-In Profile
    Follow Me on Twitter!
    Wednesday, June 22, 2011 2:20 PM
    Moderator
  • Hi Jehanzeb Javeed,

    Where do I have to write that code? OnSave event of which from??

    And what parameter is being passed?

    Thursday, June 23, 2011 4:47 AM
  • I think i need to explain. I am not talking about the Resolve a case button on the Case form.

    When we go to Service>click on Cases, a lit of cases are displayed. When we choose a case(by clicking on the checkbox near the name os the Case), we see a 'Resolve a Case'. When I click on that, I want a window to pop up.

    I hope i am clear now.


    Thursday, June 23, 2011 5:05 AM
  • Hi Swesa,

    I am afraid that if you want to perform this functionality from Case Entity List Page then you might need to hide the exsisting button and create your own button "Resolve a Case" that will call your custom JScript function to first open your custom popup window and then open the system window (Open window and see its URL path in status bar) or you can create your own Aspx page that will take all your custom data, case resolution fields data and then will execute SDK CloseIncidentRequest Message to close the case or else you may use the earlier provided solution from Case form Resolve a Case button.

    I hope this will be helpful.


    Jehanzeb Javeed

    http://worldofdynamics.blogspot.com
    Linked-In Profile |CodePlex Profile

    If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".
    Thursday, June 23, 2011 9:35 AM
  • Hi Jehanzeb Javeed,

    How do i call the pop up window that is already there?? Where is the code for that? Because, i do not want to change the existing functionality of "Resolve a Case", I just want to add one more pop up window. Can you tell me how to get the code for the existing window that pops up?

    Friday, June 24, 2011 9:14 AM
  • Hi Jehanzeb, I want to try your code, // Your custom code will come here o what does this code do?  Is that specific to custom pop-up form.   Is it possible to use your code to force to user to enter some section within the CASE entity itself <that would otherwise go in to case resolution form> and then display the default case resoluton form?  
    Friday, August 19, 2011 12:17 PM
  • Hi,

    Custom code mean JScript code (you may perform validations, show fields, hdie fields etc) I would suggest you to the reffer the following post: http://worldofdynamics.blogspot.com/2011/08/dynamics-crm-2011-perform-jscript.html


    Jehanzeb Javeed

    http://worldofdynamics.blogspot.com
    Linked-In Profile |CodePlex Profile

    If you find this post helpful then please "Vote as Helpful" and "Mark As Answer".
    Friday, August 19, 2011 12:25 PM