Thread: Favorites.xla
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
GregR GregR is offline
external usenet poster
 
Posts: 246
Default Favorites.xla

Dick Krusleika, has an add-in, favorites.xla that adds a favorite list
to the File Menu. It limits the list to 9 files, which I have changed
to 15 files and thus, this line in the add-in fails to open any files
10 - 15:

With CommandBars.ActionControl
'Try to open the file
sCap = HandleAmp(Right(.Caption, Len(.Caption) - 3), _ False)
On Error Resume Next
Set wb = Workbooks.Open(sCap)
On Error GoTo 0

I need an or statement, such as:

Or sCap = HandleAmp(Right(.Caption, Len(.Caption) - 4), False)

but it doesn't work. How do I make it work? TIA

Greg