File.Exists missing

  • Thread starter Thread starter Anil Gupte
  • Start date Start date
A

Anil Gupte

In one application I have used File.Exists and in the other one it will not
let me use it. It says:

Name 'File' is not declared

Same computer, same copy of VS Studio .Net 2003, but different results....
What gives?

Thanx,
 
Anil said:
In one application I have used File.Exists and in the other one it will not
let me use it. It says:

Name 'File' is not declared

Same computer, same copy of VS Studio .Net 2003, but different results....
What gives?

I think you need to have an :

Imports System.IO

to use the File Class without fully qualfying the name.

IOW, System.IO.File.Exists should work with or without the Imports.
 
Back
Top