Can't start outlook from Excel
Obviously Outlook is installed because (as per my first post) I can open
it manually......
"Bob Phillips" wrote in message
...
Doesn't that suggest that Outlook is not installed?
--
HTH
Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
"Susan Lammi" wrote in message
...
Sorry but No, I already looked there and outlook is not starting......
The application error I get "The instruction at 0x309ad857 referenced
memory at 0x00000000. The
memory could not be read.
translates to VBA error 429.
Checking the help files suggests that automation can't find the
license
key or some such thing....
thanks anyway
"Bob Phillips" wrote in message
...
Susan,
I think you will find that you have started Outlook, you just
haven't
made
it visible. Step through your code again and look at the Processes
tab
in
the Windows Task Manager, you should see an OUTLOOK.EXE in there.
Unfortunately, Outlook doesn't have a Visible property like Word or
Excel,
so we have to be smarter. What we need to do is open one of the
special
folders, such as the Inbox. Try this code
Dim ol As Outlook.Application
Dim olNameSpace As Outlook.NameSpace
Dim olInbox As Outlook.MAPIFolder
Set ol = New Outlook.Application
Set olNameSpace = ol.GetNamespace("MAPI")
Set olInbox = olNameSpace.GetDefaultFolder(olFolderInbox)
'Make Outlook visible
olInbox.Display
--
HTH
Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
"Susan Lammi" wrote in message
...
I am unable to start Outlook from Excel (VBA) using either of the
following. I would prefer early binding but will take either....
Both of the set commands results in an Application error
"The instruction at 0x309ad857 referenced memory at
0x00000000.
|