Sign in to follow this  
Followers 0
J0ker

Files Check Error

5 posts in this topic

I want to make a test at the beginning of my script to see if all the files are in the folder. Wich command should I use to run a test and check if the desired file is in the folder? I do not want to open the file but just check if all the files are there.

Shellexecute + return?

Share this post


Link to post
Share on other sites



FileExists ?

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Thanks helge it work!

Is there a way to make a protection?

Ex: I have a file named Readme.txt. I made this to make sure the file is in the folder.

If FileExists(@SCRIPTDIR & "\Readme.txt") Then
    Else
        MsgBox(0,"Directory Error","Cannot find Readme.txt")
        Sleep(50)
        Exit
    EndIf

If the user delete MY readme.txt and make another readme.txt, it will work too. Is there a way to prevent that to make sure that only my readme will work.

Edited by J0ker

Share this post


Link to post
Share on other sites

well, you may wish to have your program check on the following:

1) Search for "certain" data in the txt file

2) Compare filesize


mouse not found....scroll any mouse to continue.

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

Searching for a certain data will be the easiest way I think.

Thank you!

Edited by J0ker

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0