bluerein Posted November 13, 2008 Posted November 13, 2008 so youre using 1 for on and 0 for off?? just use $startupsound = IniRead(@ScriptDir & "\settings", "settings", "startupsound", "") If $startupsound = "1" Then SoundPlay(@ScriptDir & "\sound.wav", 1)
ajag Posted November 13, 2008 Posted November 13, 2008 The .ini file is okay and everything... weirdThen show us your inifile. Rule #1: Always do a backup Rule #2: Always do a backup (backup of rule #1)
bluerein Posted November 13, 2008 Posted November 13, 2008 $startupsound = IniRead("settings.ini", "settings", "startupsound", "") If $startupsound = "1" Then SoundPlay(@ScriptDir & "\sound.wav", 1) settings.ini [settings] startupsound=1 this works fine
ajag Posted November 13, 2008 Posted November 13, 2008 LOL...I didnt notice that for a while!! I thought the filename was "settings" without an extension. $startupsound = IniRead(@ScriptDir & "\settings.ini", "settings", "startupsound", "NotFound") will work with a file "settings.ini" $startupsound = IniRead(@ScriptDir & "\settings", "settings", "startupsound", "NotFound") will work with a file "settings" (!!!) A-Jay Rule #1: Always do a backup Rule #2: Always do a backup (backup of rule #1)
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