Sign in to follow this  
Followers 0
stuka

,,,

6 posts in this topic

#1 ·  Posted (edited)

.

Edited by stuka

Share this post


Link to post
Share on other sites



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)

Share this post


Link to post
Share on other sites

The .ini file is okay and everything... weird

Then show us your inifile.


Rule #1: Always do a backup         Rule #2: Always do a backup (backup of rule #1)

Share this post


Link to post
Share on other sites

$startupsound = IniRead("settings.ini", "settings", "startupsound", "")
If $startupsound = "1" Then SoundPlay(@ScriptDir & "\sound.wav", 1)

settings.ini

[settings]
startupsound=1

this works fine

Share this post


Link to post
Share on other sites

LOL...I didnt notice that for a while!!

Share this post


Link to post
Share on other sites

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)

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