What Code Do I Write ?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

What code do I write when I want my main menu form to check for a file before
it opens if it cannot find the file it should not open ? for Ex. check if I
have the file C:\Windows\Sample.txt if it cannot find if it should not open
 
Allen Browne said:
If Dir("C:\Windows\Sample.txt") <> vbNullString Then

--
Allen Browne - Microsoft MVP. Perth, Western Australia

Reply to group, rather than allenbrowne at mvps dot org.



Sorry it dose not work
 
What happens? There is nothing wrong with the code Allen provided.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top