Search the Community
Showing results for tags 'not'.
-
so right now i have a small project and i wanted to print this text out every second. i have made a random number for the sleep function. but when i want to print out with the while loop it just doesn't work. Run("notepad.exe") Sleep(1000) Local $rndSleep = Int (Random(180000,240000,1000)) While $rndSleep <> 0 $rndSleep - 1 If Mod ( $rndSleep, 1000 ) == 0 Then Send("This note will show the sleeptime before closing the tabs, you got " & $rndSleep & " seconds left.") EndIf WEnd plis halp me
-
Basically i am trying to make a script that detects if the currently active window is 1920 x 1080 or bigger. If it detects a window that is active, that is indeed that size. It will do some stuff. The problem i am having is that it is detecting my desktop whenever i click on my desktop, so it's doing stuff when i don't want it to. So all i need to know, is how can i do a simple check to see if a window = a title. Here is what i have so far $wintitledesktop = WinGetTitle("[ACTIVE]") If not $wintitledesktop = "Program Manager" Then ;does stuff endif Prog
- 6 replies
-
- if
- wingettitle
-
(and 3 more)
Tagged with:
-
Don't you just love it when a regular expression comes out on top?! I know I do.. Local $hTimer = 0 $hTimer = TimerInit() For $i = 1 To 10000 _IsSystemDrive_Test_1('C') Next ConsoleWrite(TimerDiff($hTimer) & @CRLF) $hTimer = TimerInit() For $i = 1 To 10000 _IsSystemDrive_Test_2('C') Next ConsoleWrite(TimerDiff($hTimer) & @CRLF) Func _IsSystemDrive_Test_1($sDrive) Local $aArray = [@HomeDrive, _ @ProgramFilesDir, _ @SystemDir, _ @WindowsDir] For $sFilePath In $aArray If StringLeft($sFilePath, 1) = $sDrive Then Return True EndIf Next Return False EndFunc ;==
-
I´m getting mixed up! What´s the difference between: While NOT Func1() AND Func2() and While NOT Func1() AND NOT Func2() ?? I´m using lots of these and it works find, but now that I´m rewriting my script I´m mixing things up and getting unsure.
- 3 replies
-
- operators
- silly questions
-
(and 1 more)
Tagged with:
-
Instead of hijacking the other topic any further, I decided to create a new topic for the discussion of the "Not" operator. Here is the previous topic for reference: '?do=embed' frameborder='0' data-embedContent>> How is it that this works perfectly (tested and part of one of my toolsets that hundreds of techs use daily): $Authentication = InetGetSize("http://wouldntyouliketoknow.com/DeleteThisNow.txt") If Not $Authentication = 0 Then MsgBox(16, "ERROR", "The license for this product has expired.", 5) Self_Destruct() Exit EndIf As we can see, there are no parenthes