Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Outlook 11.0 Library

I have an Excel VBA program that is distributed throughout our company
nationally (1000 users). One of the features is ability for user to click a
button and it opens up Outlook with Send to, Subject and a message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a large portion
of users have older Outlook versions that creates a compile error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature works with all
users who either have Outlook 2003 or the version before this?

thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Outlook 11.0 Library

I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Outlook 11.0 Library

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks





  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Outlook 11.0 Library

Chip,
thank you thank you for your expertise, Please, what would be used in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks






  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Outlook 11.0 Library

Hi Bret

See the example for late binding on my site
On every Outlook page you can find it

For example on this page (bottom)
http://www.rondebruin.nl/mail/folder3/smallmessage.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Bret" wrote in message ...
Chip,
thank you thank you for your expertise, Please, what would be used in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks









  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Outlook 11.0 Library

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

would be

Dim OutApp As Object
Dim OutMail As Object

In general, where ever you have a variable Dim'd as As
Outlook.whatever, change it to As Object.

--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



"Bret" wrote in message
...
Chip,
thank you thank you for your expertise, Please, what would be
used in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest
version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects,
e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout
our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003
however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before
this?

thanks







  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 201
Default Outlook 11.0 Library

Ron,

Is it possible to check if Outlook is actually installed (via VBA) without
running into the Reference error?
--
Trefor


"Ron de Bruin" wrote:

Hi Bret

See the example for late binding on my site
On every Outlook page you can find it

For example on this page (bottom)
http://www.rondebruin.nl/mail/folder3/smallmessage.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Bret" wrote in message ...
Chip,
thank you thank you for your expertise, Please, what would be used in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks








  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,391
Default Outlook 11.0 Library

If you are using Late Binding:
On Error Resume Next
Set OutlookApp=CreateObject("Outlook.Application")
If OutlookApp Is Nothing Then
'Can't create Outlook. Not installed or other error
Exit Sub
End If

NickHK

"Trefor" wrote in message
...
Ron,

Is it possible to check if Outlook is actually installed (via VBA) without
running into the Reference error?
--
Trefor


"Ron de Bruin" wrote:

Hi Bret

See the example for late binding on my site
On every Outlook page you can find it

For example on this page (bottom)
http://www.rondebruin.nl/mail/folder3/smallmessage.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Bret" wrote in message

...
Chip,
thank you thank you for your expertise, Please, what would be used

in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks










  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Outlook 11.0 Library

See also
http://www.erlandsendata.no/english/...leavailableapp



--
Regards Ron de Bruin
http://www.rondebruin.nl



"NickHK" wrote in message ...
If you are using Late Binding:
On Error Resume Next
Set OutlookApp=CreateObject("Outlook.Application")
If OutlookApp Is Nothing Then
'Can't create Outlook. Not installed or other error
Exit Sub
End If

NickHK

"Trefor" wrote in message
...
Ron,

Is it possible to check if Outlook is actually installed (via VBA) without
running into the Reference error?
--
Trefor


"Ron de Bruin" wrote:

Hi Bret

See the example for late binding on my site
On every Outlook page you can find it

For example on this page (bottom)
http://www.rondebruin.nl/mail/folder3/smallmessage.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Bret" wrote in message

...
Chip,
thank you thank you for your expertise, Please, what would be used

in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks












  #10   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 201
Default Outlook 11.0 Library

Nick, Great many thanks
--
Trefor


"NickHK" wrote:

If you are using Late Binding:
On Error Resume Next
Set OutlookApp=CreateObject("Outlook.Application")
If OutlookApp Is Nothing Then
'Can't create Outlook. Not installed or other error
Exit Sub
End If

NickHK

"Trefor" wrote in message
...
Ron,

Is it possible to check if Outlook is actually installed (via VBA) without
running into the Reference error?
--
Trefor


"Ron de Bruin" wrote:

Hi Bret

See the example for late binding on my site
On every Outlook page you can find it

For example on this page (bottom)
http://www.rondebruin.nl/mail/folder3/smallmessage.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Bret" wrote in message

...
Chip,
thank you thank you for your expertise, Please, what would be used

in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks













  #11   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 201
Default Outlook 11.0 Library

Ron, perfect thanks.
--
Trefor


"Ron de Bruin" wrote:

See also
http://www.erlandsendata.no/english/...leavailableapp



--
Regards Ron de Bruin
http://www.rondebruin.nl



"NickHK" wrote in message ...
If you are using Late Binding:
On Error Resume Next
Set OutlookApp=CreateObject("Outlook.Application")
If OutlookApp Is Nothing Then
'Can't create Outlook. Not installed or other error
Exit Sub
End If

NickHK

"Trefor" wrote in message
...
Ron,

Is it possible to check if Outlook is actually installed (via VBA) without
running into the Reference error?
--
Trefor


"Ron de Bruin" wrote:

Hi Bret

See the example for late binding on my site
On every Outlook page you can find it

For example on this page (bottom)
http://www.rondebruin.nl/mail/folder3/smallmessage.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Bret" wrote in message

...
Chip,
thank you thank you for your expertise, Please, what would be used

in
place of the Outlook.Mailitem & Create.Item as shown below?

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem

Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

thank you again for your help...

"Chip Pearson" wrote:

I should have added that you should use only those objects,
methods, and properties that are present in the earliest version
of Outlook that you need to support. In other words, don't use
any new in Outlook 11.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com


"Chip Pearson" wrote in message
...
I think in this case you are stuck with using late binding.
Change all your Outlook type variables to simple Objects, e.g.,
change
Dim AddrEntry As Outlook.AddressEntry
to
Dim AddrEntry As Object

and create the Outlook Application using CreateObject or
GetObject.

Dim OL As Object
On Error Resume Next
Set OL = GetObject(, "Outlook.Application")
If OL Is Nothing Then
Set OL = CreateObject("Outlook.Application")
End If


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com




"Bret" wrote in message
...
I have an Excel VBA program that is distributed throughout our
company
nationally (1000 users). One of the features is ability for
user to click a
button and it opens up Outlook with Send to, Subject and a
message all filled
in and user can of course just click the SEND button.
It works for majority of users who have Outlook 2003 however a
large portion
of users have older Outlook versions that creates a compile
error or missing
Reference errors, again program uses Outlook 11.0 library.
What can be done in code or with references so this feature
works with all
users who either have Outlook 2003 or the version before this?

thanks













Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Microsoft Outlook Library splodgey Excel Discussion (Misc queries) 2 August 9th 07 03:58 PM
Outlook 11 Outlook 10 Object Library Compatibility Issues Paul Mac[_4_] Excel Programming 11 May 19th 06 04:27 AM
Attaching an Outlook Library programatically Richard Buttrey Excel Programming 3 August 4th 05 10:47 AM
Late Binding to Outlook from Excel: Outlook modifies email body Lenny Wintfeld Excel Programming 0 December 12th 04 04:03 PM
Reference Library - Missing Library in a lower version. luvgreen Excel Programming 1 October 7th 04 02:08 AM


All times are GMT +1. The time now is 02:10 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"