Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Pro VB 6
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Pro VB 6 For advanced Visual Basic coders working in version 6 (not .NET). Beginning-level questions will be redirected to other forums, including Beginning VB 6.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old August 11th, 2004, 11:00 AM
Registered User
 
Join Date: May 2004
Location: , , .
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default Outlook Automation Error

:(I am running WinXP Professional SP1, Outlook 2002 (I have installed all critical windows updates). I've run this code a million times before, no problem. Recently I've been getting a 'Choose Profile' dialog and a Windows Script Host error when running the code in vbs. This only happens if there is no Outlook running at all. If Outlook is running, I do not get an error. This happens regardless of number of profiles setup, or if any of these profiles is the default or not. The first time it runs, I get the login dialog and the error, but an Outlook object is created, as I can see it in Task Manager. I run the code again, and this time no error since Outlook has been instantiated. Has anyone come across this problem? Any suggestions?

The error is:

Code: 80010108
Error: The object invoked has disconnected from its clients.


The code is:

Set oOL = CreateObject("Outlook.Application")
Set oOL = Nothing
:(

Reply With Quote
  #2 (permalink)  
Old August 11th, 2004, 11:26 AM
Friend of Wrox
 
Join Date: Aug 2003
Location: , , .
Posts: 205
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Have you tried running this program on other machines? What happens when you open outlook manually?
Reply With Quote
  #3 (permalink)  
Old August 11th, 2004, 03:53 PM
Registered User
 
Join Date: May 2004
Location: , , .
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Yes, I run this program on another machine with the same configuration. It does not error. The object is created and destroyed without slapping the user with a dialog or an error message.

Starting Outlook manually works fine, as expected.

Reply With Quote
  #4 (permalink)  
Old August 12th, 2004, 04:09 AM
Authorized User
 
Join Date: Apr 2004
Location: , , .
Posts: 17
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The only idea I can get - try referencing Outlook directly - adding the reference to the project instead of using CreateObject.


webdesign
Reply With Quote
  #5 (permalink)  
Old August 12th, 2004, 09:09 AM
Friend of Wrox
 
Join Date: Aug 2003
Location: , , .
Posts: 205
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Have you tried running a detect and repair on Outlook?
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Automation Error nagarajan123 Access 0 April 30th, 2008 09:22 AM
Outlook Automation in Access arielalevy Access VBA 1 June 27th, 2006 07:00 PM
Outlook '03 automation from Access '03 error Derek_05 Access VBA 2 February 3rd, 2006 06:09 AM
error 7866 when using automation pilmart Access 0 August 29th, 2003 02:57 PM
Outlook 2000 Automation byron Pro VB 6 4 July 10th, 2003 01:10 AM



All times are GMT -4. The time now is 09:23 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.