PDA

View Full Version : Help:Left Function Library



yurble_vn
08-04-2007, 11:55 PM
Hi All,

AddinTitle = Left(.Name, Len(.Name) - 4)

I found a code in articles thread with the above code. But when run, excel return: can not find project or library.

Anyone know what is the library Left code belong to? Please help...

RichardSchollar
08-05-2007, 01:11 AM
Hi

That's the VBA lib so:


Msgbox VBA.Left(mystring,5)

for example. I suspect that this isn't the root cause of your problem, however.

Bob Phillips
08-05-2007, 05:52 AM
Go to the VBIDE, Alt-F11, and check your references, Tools>References. If any are MISSING, uncheck them.

yurble_vn
08-05-2007, 08:25 AM
Msgbox VBA.Left(mystring,5)
Yep. This is the one run okie in my excel. Thanks all for prompt support.

For you all information. This is the code in StartUpManager that I loaded in Articles thread. (AddIn Creating Articels)

There is also another error return in followlings code:
If MsgBox(" The target folder already contains a file with the same name... " & _
vbNewLine & vbNewLine & _
" (That file was last modified on: " & _
Workbooks(AddinName) _
.BuiltinDocumentProperties("Last Save Time") & ")" & _
vbNewLine & vbNewLine & vbNewLine & _
" Would you like to replace the existing file with this one? " & _
vbNewLine & vbNewLine & _
" (This file was last modified on: " & _
.BuiltinDocumentProperties("Last Save Time") & ")", vbYesNo, _
"Add-in Is In Place - Confirm File Replacemant...") = vbYes Then
Workbooks(AddinName).Close False
Kill Application.UserLibraryPath & AddinName
Call InstallAddIn
End If

Which return : Subscript out of range.

I dont know whether it's the code error or my excel have not proper configured. But after reduce the text in above code. It works okie with my excel.

yurble_vn
08-05-2007, 08:35 AM
Forgot to say: when open the workbook, there is a message as following:

Compile error on hidden module: ThisWorkBook.

And I also forward the link of the file which is uploaded at articles thread:

http://vbaexpress.com/forum/attachment.php?attachmentid=4702&d=1168225873