DoctorX Posted August 29, 2005 Posted August 29, 2005 $CDDir = FileReadLine ($file, 18) $Shortcuts = FileReadLine ($file, 21) $ShortDir = FileReadLine ($file, 24) If @error <> 0 Then ErrorFunc ("The data in the " & @ScriptDir & "\Data\F4DP.cfg file is missing or corrupt.", _ "GetUserData-FileReadLine") EndIf Will this check for errors on all 3 instances of FileReadLine or just the last one? -DRX
LxP Posted August 29, 2005 Posted August 29, 2005 Only the last instance will be error-checked, but if the last call generates an error then you can probably safely bet that the first two also did. Also, the following two lines of code are equivalent: if @error <> 0 then if @error then
DoctorX Posted August 29, 2005 Author Posted August 29, 2005 Thanks again Alex. Keep up the advice and I may have to add a co-author credit in my script! -DRX
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now