Jump to content
Sign in to follow this  
gcue

is not equal <> ?

Recommended Posts

gcue

trying to express not equal to.. tried <> but it didnt seem to work

If $broadcast="2" Then
$broadcast="Disabled"
EndIf

If $broadcast <> "2" Then
$broadcast="Enabled"
EndIf

Share this post


Link to post
Share on other sites
someone

Other then what Val said only thing is in this code if $broadcast="2" then the value for $broadcast will be overwritten with "Disabled", thus satisfying $broadcast<>"2" (because it now equals "Disabled") which then make it "Enabled"


While ProcessExists('Andrews bad day.exe')
	BlockInput(1)
	SoundPlay('Music.wav')
	SoundSetWaveVolume('Louder')
WEnd

Share this post


Link to post
Share on other sites
Valuater

Other then what Val said only thing is in this code if $broadcast="2" then the value for $broadcast will be overwritten with "Disabled", thus satisfying $broadcast<>"2" (because it now equals "Disabled") which then make it "Enabled"

good point.... :D

I was sure he was testing by "numbers"

Another approach

$broadcast = 1

If $broadcast = "2"  Then
    $broadcast = "Disabled" 
Else
    $broadcast = "Enabled" 
EndIf

MsgBox(0x0, "", $broadcast)

8)

Edited by Valuater

NEWHeader1.png

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  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.