locked
Dynamics 4 Service - When I double click on an email address, why doesn't it open an email with the alias embedded? RRS feed

  • Question

  • Is there a setting to activate email fields so an email automatically opens with the address embedded?

    Thanks

     


    Scott Clancy
    Wednesday, March 2, 2011 11:14 PM

Answers

  • There is not. But if you put this jscript into the onload event of the contact form then when you double click on the email field it will open up an email form.

    if(crmForm.FormType == 1 || crmForm.FormType == 2)
    {
            crmForm.all.emailaddress1.ondblclick = function() 
            {
                    var email = crmForm.all.emailaddress1.DataValue;
                    if ((email != null) && (email.length > 0)) 
                    {
                       window.navigate("mailto:" + email);
                    }
                                    
            }
    }
    

    Jerry CRM Innovation - Need a solution for CRM to help you manage Events or Email Marketing? Follow me on Twitter
    Thursday, March 3, 2011 9:03 PM

All replies

  • There is not. But if you put this jscript into the onload event of the contact form then when you double click on the email field it will open up an email form.

    if(crmForm.FormType == 1 || crmForm.FormType == 2)
    {
            crmForm.all.emailaddress1.ondblclick = function() 
            {
                    var email = crmForm.all.emailaddress1.DataValue;
                    if ((email != null) && (email.length > 0)) 
                    {
                       window.navigate("mailto:" + email);
                    }
                                    
            }
    }
    

    Jerry CRM Innovation - Need a solution for CRM to help you manage Events or Email Marketing? Follow me on Twitter
    Thursday, March 3, 2011 9:03 PM
  • Hi Jerry thanks,  two questions about this script:

    1. why the form check at the begining?

    2. If the record has a change on it, I get a pop up that says do you want to naviate away from this page and at the same time the email is opened.  Once I send the email I am returned to the "do you want to navigate away" message.  Is there a way to open the email without getting that getting that message?

    Thanks 

     


    Scott Clancy
    Friday, March 4, 2011 9:46 PM
  •  

    Forget about #1, I see it's looking to see if the form is create or update


    Scott Clancy
    Friday, March 4, 2011 10:22 PM
  • let me take a look at the code again and get back  to you.
    Jerry CRM Innovation - Need a solution for CRM to help you manage Events or Email Marketing? Follow me on Twitter
    Friday, March 4, 2011 11:20 PM
  • Scott,

    I just looked at the code again and then inserted into the contact entity in one our clean demo orgs. Works like a champ for me. So I am little perplexed on the warning message you are getting. Do you have any other onload event code on the entity?


    Jerry CRM Innovation - Need a solution for CRM to help you manage Events or Email Marketing? Follow me on Twitter
    Friday, March 4, 2011 11:28 PM
  • Nothing else there. 

     

    Try creating a new record, add the email address and then double click on the email address.  The email opens but behind it is the navigation message.  I think it's because it's wants you to save your changes before naviating away from the form.

    It works fine for record that I have not changed prior to double clicking.

    Scott


    Scott Clancy
    Friday, March 4, 2011 11:30 PM