LongBowNZ Posted August 14, 2007 Posted August 14, 2007 Is there a certain code that tells the script to do nothing in an If Else, eg: If FileExists($IniDr) Then ; Do nothing code here Else IniWrite("testingsettings.ini", "Options", "No_Video", "1") IniWrite("testingsettings.ini", "Options", "Close_ML", "1") EndIf It works without something there but just seems weird to me.
ResNullius Posted August 14, 2007 Posted August 14, 2007 Is there a certain code that tells the script to do nothing in an If Else, eg: If FileExists($IniDr) Then ; Do nothing code here Else IniWrite("testingsettings.ini", "Options", "No_Video", "1") IniWrite("testingsettings.ini", "Options", "Close_ML", "1") EndIfoÝ÷ ÚÞ½éÚºÚ"µÍYÕ[Q^ÝÊ ÌÍÒ[QH[[UÜ]J ][ÝÝÝ[ÜÙ][ÜË[I][ÝË ][ÝÓÜ[ÛÉ][ÝË ][ÝÓ×ÕY[É][ÝË ][ÝÌI][ÝÊB[UÜ]J ][ÝÝÝ[ÜÙ][ÜË[I][ÝË ][ÝÓÜ[ÛÉ][ÝË ][ÝÐÛÜÙWÓS ][ÝË ][ÝÌI][ÝÊB[Y
The Kandie Man Posted August 14, 2007 Posted August 14, 2007 (edited) Yes, what you are doing by coding standards is inefficient, so it makes sense that it looks weird. Not a big deal though, but this will fix your problem:If NOT FileExists($IniDr) Then IniWrite("testingsettings.ini", "Options", "No_Video", "1") IniWrite("testingsettings.ini", "Options", "Close_ML", "1") EndIf I hope that makes sense. - The Kandie Man ;-) EDIT: ResNullius beat me ;-) Edited August 14, 2007 by The Kandie Man "So man has sown the wind and reaped the world. Perhaps in the next few hours there will no remembrance of the past and no hope for the future that might have been." & _"All the works of man will be consumed in the great fire after which he was created." & _"And if there is a future for man, insensitive as he is, proud and defiant in his pursuit of power, let him resolve to live it lovingly, for he knows well how to do so." & _"Then he may say once more, 'Truly the light is sweet, and what a pleasant thing it is for the eyes to see the sun.'" - The Day the Earth Caught Fire
LongBowNZ Posted August 14, 2007 Author Posted August 14, 2007 Tried "If Not" before and it looked like it didnt work but for some stupid reason I have to 'right click - refresh' to see the file. Thanks for showing me I'm not crazy
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