View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_6_] Bob Phillips[_6_] is offline
external usenet poster
 
Posts: 11,272
Default Opening An Excel Application and "Analysis ToolPac" does not load

When you start Excel via automation, the addins are not automatically
loaded, you need to do it manually.

Here is an MS article on it

http://support.microsoft.com/kb/q213489/
XL2000: Add-Ins Don't Load When Using the CreateObject Command

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mark" wrote in message
...
When I open an Excel Application via VBA the Analysis ToolPac functions

are
not loaded. (Specially I want to see the function "EDATE" but there are
others nice functions.)

VBA:
Dim appWB As Excel.Application

Set appWB = CreateObject("Excel.Application")
appWB.Workbooks.Open Filename:="c:\mydocs\myXLWB.xls", ReadOnly:=False
appWB.Visible = True

Even when I set the addins property to True they are not recognized:

'Install Analysis Tool pack
AddIns("Analysis ToolPak").Installed = True

Any Suggestions?

Thank you,
Mark