Programming with Outlook

  • Thread starter Thread starter henrycortezwu
  • Start date Start date
H

henrycortezwu

Hi All,
I'm thinking of including this method of sending attachments using
the code in the link below, it uses Outlook Objects.

How to send attachments in an e-mail message by using Visual Basic .NET
http://support.microsoft.com/default.aspx?scid=kb;en-us;313803

Several Questions,
1) When I create the Setup Program for my application is it legally
right to include the Outlook dll?

2) If a client w/o MS Outlook uses my app, will the applicaton fail to
"launch" from the start, or just the "form" that uses the outlook dll?

3) I plan to use Outlook Object 10 instead of 11, will version 10 work
with clients with Outlook 2003?

4) Is it possible to "catch" clients w/o Outlook installed?

5) Is it possible to "catch" clients w/ incompatible versions of
Outlook, say Outlook 98, if I decided to use Outlook XP dll or version
10?

Thanks so much!!
Henry :)
 
Hi All,
I'm thinking of including this method of sending attachments using
the code in the link below, it uses Outlook Objects.

How to send attachments in an e-mail message by using Visual Basic .NET
http://support.microsoft.com/default.aspx?scid=kb;en-us;313803

Several Questions,
1) When I create the Setup Program for my application is it legally
right to include the Outlook dll?

No it is illegal

Does this than answer the rest of your questions as well.

Cor
 
Thanks for the quick reply,
I guess I'll have to do a late bind of the Outlook object instead.

Thanks again!!
Henry :)
 
On 23 Jul 2005 20:49:22 -0700, (e-mail address removed) wrote:

¤ Hi All,
¤ I'm thinking of including this method of sending attachments using
¤ the code in the link below, it uses Outlook Objects.
¤
¤ How to send attachments in an e-mail message by using Visual Basic .NET
¤ http://support.microsoft.com/default.aspx?scid=kb;en-us;313803
¤
¤ Several Questions,
¤ 1) When I create the Setup Program for my application is it legally
¤ right to include the Outlook dll?
¤

No.

¤ 2) If a client w/o MS Outlook uses my app, will the applicaton fail to
¤ "launch" from the start, or just the "form" that uses the outlook dll?
¤

Not if you use late binding, which you should use if you're supporting multiple versions of Outlook.

¤ 3) I plan to use Outlook Object 10 instead of 11, will version 10 work
¤ with clients with Outlook 2003?
¤

Probably, but you should always develop for the oldest version supported.

¤ 4) Is it possible to "catch" clients w/o Outlook installed?
¤

Yes. You can check if Outlook has been installed using API function calls, such as FindExecutable,
or trap the error that occurs when you attempt to create the Outlook object.

¤ 5) Is it possible to "catch" clients w/ incompatible versions of
¤ Outlook, say Outlook 98, if I decided to use Outlook XP dll or version
¤ 10?

Probably. The most reliable method would be to find the Outlook executable (using FindExecutable)
and then retrieve the version info. Below is an example:

Declare Function FindExecutable Lib "shell32.dll" Alias "FindExecutableA" (ByVal lpFile As
String, _
ByVal lpDirectory As
String, _
ByVal lpResult As
System.Text.StringBuilder) As Int32

Function IsOutlookInstalled(ByRef FileVersionMajor As String) As Boolean

Dim DummyFile As String
Dim FileDir As String

Dim FilePath As New System.Text.StringBuilder(255)
DummyFile = "e:\My Documents\dummy.fav"

If FindExecutable(DummyFile, FileDir, FilePath) > 32 Then
Console.WriteLine(FilePath)
IsOutlookInstalled = True
FileVersionMajor =
System.Diagnostics.FileVersionInfo.GetVersionInfo(FilePath.ToString).FileMajorPart
End If

End Function


IsOutlookInstalled(FileVersionMajor)



Paul
~~~~
Microsoft MVP (Visual Basic)
 

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

Back
Top