LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
eXcellence
 
Posts: n/a
Default Calling a common XLA Library file, stored on a network drive :)

Hiya Forumittes,

Progress!!!

I can now call and update a Library (xla) file from the network and
install it when the workbook opens.

But << there is always a but...

1) I call and install the Library file.

Private Sub Workbook_Open()

Application.DisplayAlerts = False

AddIns("Excel_Library3").Installed = False 'To remove current link
AddIns.Add Filename:= _

"G:\Users\Development_Applications\Site_Library\Ex cel_Library3.xla"
AddIns("Excel_Library3").Installed = True
Application.DisplayAlerts = True

If AddIns("Excel_Library3").Installed = True Then
MsgBox "add-in is installed"
Else
MsgBox "add-in is not installed"
End If
End Sub


* Good so far... i get a message saying "add-in is installed"

2) for testing i have put a button on the sheet just to call a function
in the library.

Private Sub CommandButton1_Click()
MsgBox (get_date())
MsgBox (get_time())
End Sub

* I push the button and i get an error "Sub or Function not defined"

* i stop the program and look at the references, the library is NOT
ticked.
* if i tick it, and type in "get_" (then press Ctl_Space, to do a word
completion the function "get_date and get_time" are visible.

* i run the program again. and it fails.

----
This is the code in the library, all PUBIC stuff, so im at a loss.

Public Function Get_Time() As Date
Get_Time = Time
End Function
Public Function Get_Date() As Date
Get_Date = Date
End Function

-------

Im soooo close, i recon, i need to force the TICK somehow, but i
thought this piece of code did that:

AddIns("Excel_Library3").Installed = True

 
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
Calling a common XLA Library file, stored on a network drive :) eXcellence Excel Discussion (Misc queries) 5 June 28th 05 02:10 PM
When calling a different file, can I make the tab equal to a cell? thebigd08 Excel Discussion (Misc queries) 1 June 24th 05 12:39 AM
Does anyone know where the auto recovery file are stored on the? Husker87 Excel Discussion (Misc queries) 1 January 27th 05 01:17 AM
Weekly Transaction Processing Ralph Howarth Excel Worksheet Functions 4 January 19th 05 05:37 AM
Read Text File into Excel Using VBA Willie T Excel Discussion (Misc queries) 13 January 8th 05 12:37 AM


All times are GMT +1. The time now is 08:50 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"