Jump to content

Recommended Posts

Posted

While Not $a = 5
   ; DOIT()
 WEnd

Missed code tag.

No, you're wrong.

while $a <> 5 
    DOIT() 
    WEnd

Broken link? PM me and I'll send you the file!

Posted (edited)

While Not $a = 5
  ; DOIT()
 WEnd

Missed code tag.

Totally wrong. That code is:

While (Not $a) = 5

Where Not $a evaluates to either True or False.

Edited by Valik
Fixed post due to broken autoit tags.
Posted

Technically, (not $a == 5) would be more like C if you know that $a is a variant.

Discuss.

I fail to see what further misinformation achieves. This is the exact same answer James gave and is the wrong answer.
Posted

Seeing as your tags now read "While (Not $a) = 5oÝ÷ Ùhbr¬èr·¬¦§µçhºØ¬ë-jëh×6While $a <> 5" the discussion was hard to follow.

Fixed.

More correct would be: While (Not ($a == 5)).

No, more correct would be While $a <> 5. Your code needless uses parenthesis for grouping (The outer pair). Then it needlessly performs an equality comparison and then inverts the result. Why do all that in so many steps and cause so much extra parsing to be involved when you can just use <> and get it all done in one go? That's like using this code to test for greater-than-or-equal:

If Not ($a < 3) Then

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
×
×
  • Create New...