Find path to outlook.exe

H

Hugh self taught

Hi guys,

This is the code I'm currently using to open outlook. (Borrowed it from this
forum somewhere) I may want to put the front end onto multiple machines at
some stage (my own other is an XP 64bit) & the version of Office may be
different so pathing will differ. What would the most efficient way be to
determine where outlook.exe resides & invoking it? I don't want to have to
re-code the database for each machine individually.

Dim retVal As Double

retVal = Shell("C:\Program Files\Microsoft Office\OFFICE12\OUTLOOK.EXE",
vbNormalFocus)

If (retVal = 0) Then
MsgBox "Failed to open Outlook."
End If

Thanks in advance for any guidance on this
 
H

Hugh self taught

Well that was a thought I had but never got around to trying. It works on my
laptop. I'll test it on my x64 machine where XP seems a bit more picky about
where an app executable is located. I'll post back on that although I'm still
keen on getting the API to work as well for future ref / use.
 
H

Hugh self taught

Well that was a thought I had but never got around to trying. It works on my
laptop. I'll test it on my x64 machine where XP seems a bit more picky about
where an app executable is located. I'll post back on that although I'm still
keen on getting the API to work as well for future ref / use.
 
H

Hugh self taught

Okay it's after midnight & I have a heavy day tomorrow but I can't sleep
until I'd tested this on my x64 machine & it works fine there as well.
Tomorrow evening I'll play around with the sample code I downloaded to auto
re-link a BE to the FE then this DB is completed & on to the next project.
 
H

Hugh self taught

Okay it's after midnight & I have a heavy day tomorrow but I can't sleep
until I'd tested this on my x64 machine & it works fine there as well.
Tomorrow evening I'll play around with the sample code I downloaded to auto
re-link a BE to the FE then this DB is completed & on to the next project.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top