Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Len Len is offline
external usenet poster
 
Posts: 162
Default Existing File Not Found

Hi,

I'm not sure why the following vba code does not work as intended if
the existing excel file is found and activate but it keeps prompting
the error message that the file is not found

Dim Wbk As Workbook
For Each Wbk In Workbooks
If Wbk.Name = "GL.xls" Then
Windows("GL.xls").Activate
Else
MsgBox " The required file is not found - process end"
Exit Sub
End If
Next Wbk

Please help, thanks in advance

Regards
Len
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
Open File - Need an warning to appear if file cannnot be found Brite Excel Programming 3 April 17th 07 05:56 PM
Importing text file, only option to edit existing file smokey99 Excel Discussion (Misc queries) 8 April 26th 06 09:08 PM
How to change closed file name - Error: file not found PGM Excel Programming 5 April 18th 06 02:07 PM
File Not Found menu pops up after I open a file Harveytunes Excel Discussion (Misc queries) 3 January 27th 06 07:23 PM
How do I reference external data from a file, file name found in . Clux Excel Discussion (Misc queries) 1 February 10th 05 10:52 PM


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