LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default check for valid file

I'm using a routine to run thru a list of files and open them to modif
certain things.

here is the chunk of code that open uo the file and activates it

Workbooks.Open WindowName
Windows(WindowName + ".xls").Activate

how can check to see if a file exist before I attempt to open it?

the minute it hist the first line,if the file does not exist..i
crashes.
I need to be able to check first to be able to handle non existin
files.

thanks

Pab

--
Message posted from http://www.ExcelForum.com

 
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
file format or file extension is not valid...error message Ballun Excel Discussion (Misc queries) 0 May 7th 09 09:06 PM
Formula to check against a list of valid values Barb W[_2_] Excel Worksheet Functions 3 March 4th 08 06:51 PM
How to check valid Date value? hstijnen Excel Worksheet Functions 1 August 14th 06 01:25 PM
Frequently used file suddenly becomes 'not a valid file name' Dirk Bordet Excel Worksheet Functions 0 June 6th 05 05:53 PM
Algorithim to generate/check valid serial keys brettdj Excel Programming 0 November 25th 03 12:06 AM


All times are GMT +1. The time now is 03:58 PM.

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"