Sign in to follow this  
Followers 0
PantZ4

How does filefind works?

3 posts in this topic

#1 ·  Posted (edited)

Why does this script not work

;Search for the .ini settings.
$ini = FileFindFirstFile(@workingdir & "\settings.ini")
If @error = 1 Then
    MsgBox(48,"File missing.","settings.ini is missing!")
    Exit
EndIf
FileClose($ini)oÝ÷ ØZ½éèµÊÞj×­è§ø¥{'­²Ø¥+pYg¢ÛÊØ^­èZ²©¥éÝiê뢴ájy2¢áÒ!j÷Ê-¯'jëh×6If @error = -1 Then

Edited by Mr. Zero

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

You need to test the returned value , not @error:

;Search for the .ini settings.
$ini = FileFindFirstFile(@workingdir & "\settings.ini")
If $ini = -1  Then
    MsgBox(48,"File missing.","settings.ini is missing!")
    Exit
EndIf
FileClose($ini)
Edited by JdeB

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

Why does this script not work
;Search for the .ini settings.
$ini = FileFindFirstFile(@workingdir & "\settings.ini")
If @error = 1 Then
    MsgBox(48,"File missing.","settings.ini is missing!")
    Exit
EndIf
FileClose($ini)oÝ÷ ØZ½éèµÊÞj×­è§ø¥{'­²Ø¥+pYg¢ÛÊØ^­èZ²©¥éÝiê뢴ájy2¢áÒ!j÷Ê-¯'jëh×6If @error = -1 ThenoÝ÷ Ûú®¢×ºÚ"µÍÈ  ][ÝÔ]ÈLHYÜØØÝË][ÝÈÕÜÈLBÔÙXÚÜH[HÙ][ÜËÌÍÚ[HH[Q[Ý[JÛÜÚ[Ù   [È ][ÝÉÌLÜÙ][ÜË[I][ÝÊBY   ÌÍÚ[HHLH[ÙÐÞ
    ][ÝÑ[HZÜÚ[Ë][ÝË  ][ÝÜÙ][ÜË[HÈZÜÚ[ÉÌÌÎÉ][ÝÈ    [È [ÈÜB^][Y[PÛÜÙJ ÌÍÚ[J

Someone was faster...

Edited by BugFix

Best Regards BugFix  

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