You must Sign In to post a response.
  • Category: Microsoft Dynamics

    Unable to create Outlook

    Hi ,

    Below is the lines of code which iam using to open outlook while running outof browser application with silver light

    it throws a exception "Failed to create an object instance for the specified ProgID" please suggest

    dynamic outLook = null;
    bool retval = false;
    try
    {
    outLook = AutomationFactory.GetObject("Outlook.Application");
    if (outLook != null)
    {
    retval = true;
    }
    }
    catch (System.Exception ex)
    {
    }
    if (!retval)
    {
    try
    {
    outLook = AutomationFactory.CreateObject("Outlook.Application");
    }
    catch (System.Exception ex)
    {
    TSDialog.alert(ex.Message, TelStrat.Assets.Resource.MessageInfoAccessOutlook);

    }
    }
    if (outLook != null)
    {
    var olMail = outLook.CreateItem(0);
    olMail.Attachments.Add(EmailPath);
    olMail.Display();
    olMail.Save();
    }
  • #638530
    try this if the client has outlook

    http://timheuer.com/blog/archive/2010/03/15/whats-new-in-silverlight-4-rc-mix10.aspx

    com object must be signed before using it

    http://stackoverflow.com/questions/2069734/problem-in-comautomationfactory-createobject


  • This thread is locked for new responses. Please post your comments and questions as a separate thread.
    If required, refer to the URL of this page in your new post.