Error Retrieving COM object

Discussion in 'ASP .Net' started by Klaki, Dec 12, 2006.

  1. Klaki

    Klaki Guest

    I'm trying to create an instance of Outlook using VB.net and every time
    I run the site, I get the following error: Retrieving the COM class
    factory for component with CLSID {0006F03A-0000-0000-C000-000000000046}
    failed due to the following error: 80010001. If I run debug on my PC
    using Visual Sturdio 2005, it works, but when I publish it to the web
    server, I get the error. I have Office installed on the web server
    with the Interop files. Is there something else that I'm missing.
    Here is the code if anyone is interested:

    Dim taskBody As String
    Dim oOutlook As Outlook.Application
    Dim oNS As Outlook.NameSpace
    Dim oItem As Outlook.TaskItem
    Dim oItem2 As Outlook.TaskItem

    oOutlook = New Outlook.Application
    oNS = oOutlook.GetNamespace("MAPI")
    oItem = oNS.Folders.Item("Public Folders").Folders("All Public
    Folders").Folders("My Folder").Folders("SubF").Items.Add(3)
    oItem2 = oNS.Folders.Item("Public Folders").Folders("All Public
    Folders").Folders("MyFolder").Folders("SubF2").Folders("SubF3").Items.Add(3)
    taskBody = strBody

    With oItem
    .StartDate = Now
    .DueDate = Now
    .Owner = "Me"
    .Subject = "My Subject"
    .Body = taskBody
    .Importance = 2
    .ReminderSet = False
    .Close(0)
    End With

    With oItem2
    .StartDate = Now
    .DueDate = Now
    .Owner = "Me"
    .Subject = "My Subject"
    .Body = taskBody
    .Importance = 2
    .ReminderSet = False
    .Close(0)
    End With

    Any ideas or clues would be greatly appreciated

    Thanks in advance,
    Klaki
     
    Klaki, Dec 12, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?QnJpYW4gQmFybmV0dA==?=

    retrieving PDF file with ServerXMLHTTP object

    =?Utf-8?B?QnJpYW4gQmFybmV0dA==?=, Feb 14, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    1,245
    =?Utf-8?B?QnJpYW4gQmFybmV0dA==?=
    Feb 15, 2004
  2. Boban Dragojlovic
    Replies:
    2
    Views:
    517
    Patrice
    Apr 19, 2004
  3. =?Utf-8?B?RGlmZmlkZW50?=

    Retrieving expiration date of cache object

    =?Utf-8?B?RGlmZmlkZW50?=, Jan 19, 2006, in forum: ASP .Net
    Replies:
    0
    Views:
    351
    =?Utf-8?B?RGlmZmlkZW50?=
    Jan 19, 2006
  4. Replies:
    3
    Views:
    360
    Victor Bazarov
    Jun 6, 2007
  5. steen
    Replies:
    8
    Views:
    533
    Esmond Pitt
    Jun 20, 2007
Loading...

Share This Page