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

I have an application that gets deployed to several
different computers (with different OS and Excel
versions). Within the Excel application there are several
macros. I need to use many of the supplied Excel
library's. I add a reference to them, and compile my
project. I even have a function that searches to find any
missing libraries, it them removes the missing libraries
and readd's them by using both the name and the GUID.
Unforntunatley, if the library reference name is
unrecongized by a different version of Excel, it will not
perform the correct actions. Instead, it will leave it
missing. When this happens, all following libraries
(whether missing or not) are not recongnized, and
therefore, my excel application produces an application
error.
I was thinking that I should create some DLL or something
to prevent this from happening, but I am having no luck. I
have had this problem for a really long time, and could
use any form of advice that anyone has.

Thanks in advance!

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Library references

Amanda,

Use late binding.

So instead of something like

Dim oOL as Outlook.Application

Set oOL = New OutLook.Application

which needs a reference, use

Dim oOL as Object

Set oOL = CraeteObject("Outlook.Application")

you won't be able to use of that app's constant variab le (such as xlYes in
Excel), but you can build with early binding, get the values, and change to
late bindin g when ready to distribute.

Here's a link to a previous, fuller, post of mine on the subject

http://makeashorterlink.com/?N32B22AF6

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Amanda" wrote in message
...
I have an application that gets deployed to several
different computers (with different OS and Excel
versions). Within the Excel application there are several
macros. I need to use many of the supplied Excel
library's. I add a reference to them, and compile my
project. I even have a function that searches to find any
missing libraries, it them removes the missing libraries
and readd's them by using both the name and the GUID.
Unforntunatley, if the library reference name is
unrecongized by a different version of Excel, it will not
perform the correct actions. Instead, it will leave it
missing. When this happens, all following libraries
(whether missing or not) are not recongnized, and
therefore, my excel application produces an application
error.
I was thinking that I should create some DLL or something
to prevent this from happening, but I am having no luck. I
have had this problem for a really long time, and could
use any form of advice that anyone has.

Thanks in advance!



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
Help with converting a block of cells with Absolute and mixed references to relative references Vulcan Excel Worksheet Functions 3 December 13th 07 11:43 PM
change VBAProject References Library amy Excel Programming 1 January 6th 04 12:55 PM
Object Library References Nelson[_5_] Excel Programming 5 December 10th 03 08:54 PM
Object Library References Nelson[_6_] Excel Programming 1 December 10th 03 03:31 AM
preserving type library references when distributing macros gene Excel Programming 0 July 11th 03 02:43 PM


All times are GMT +1. The time now is 11:19 AM.

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"