Jump to content

Klaatu

Active Members
  • Posts

    191
  • Joined

  • Last visited

Profile Information

  • Location
    Ceti-Alpha 5

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Klaatu's Achievements

Prodigy

Prodigy (4/7)

0

Reputation

  1. What is the persistency (if that's a word) of the data? Or should I say of the container? Does it exist only as long as a running script has it open? Until a shutdown? Or does it survive a reboot?
  2. Am I missing something? What code?
  3. bbuser99, Congratulations on suckering talking someone into working for you for free.
  4. Why would you want to send a mouse right click? That seems fraught with possibilities for error. Better I would think would be to send the keystrokes to open and select from the popup menu. Send('{APPSKEY}') should open up the menu. I think.
  5. New version posted. See first post for download links. Version 1.6 * changed: StripComments() and ScanForVars() now use regular expressions to greatly speed up the code instead of looping through the line character by character. * changed: turning debugging on and off is now much more flexible. In addition to skipping '# cs'/'# ce' blocks, you can now use ';debugit-off' and ';debugit-on' to stop and start debugging. * added: in addition to multi-dimensional-arrays being identified as such, objects and hwnds will too. * other minor changes too numerous to mention (or remember, frankly). Along the same lines as DebugIt, I've also come up with DebugVer, which basically does the same thing as DebugIt (in that you use it to debug your script), but instead of opening up a GUI and outputting the results there, it creates a new .au3 file from your script with debug code in it. When you run this script it will create a log file of the script's execution. Hopefully that's not too convoluted; basically from YourScript.au3 DebugVer creates YourScriptVer.au3, which when executed creates YourScriptVer_somenumber.log. I use it instead of DebugIt when interactive debugging would be inconvenient. One note, though: if your script successfully executes (ie, no errors are generated), the log file is sent to the recycle bin so as not to build up a bunch of log files. See first post for this script as well. Enjoy, Klaatu
  6. The name of that function (compared to the others) tells me to go look for a Time key on my keyboard... Not surprisingly, I do not find a Time key...
  7. Instead of passing the array to itself over and over again with each recursion, perhaps it would work better just to make the array a static variable instead. Just something to think about anyway...
  8. Ah, thanks. I had missed that when searching the help file. Very good. I'm not interested in it changing, just knowing what the rules are. Thanks again. Case closed.
  9. I searched the forum and the help file but could not find the answer to my question. Do logical expressions short-circuit? Hopefully you know what I mean. I've seen some UDFs written (specifically the one I'm looking at is the IsPressed Library UDF by FireFox) as if they do, so was curious if these UDFs need to be modified. Here's an example: $ia_R = DllCall($vDLL, 'int', 'GetAsyncKeyState', 'int', '0x' & $iHexKey) If (@Error = 0) And (BitAND($ia_R[0], 0x8000) = 0x8000) Then Return TrueIf the DllCall function fails the $ia_R may not be an array, so the reference to the variable in the next statement would error (or at least fail to work as intended) since it uses array subscripting. Correct? But if logical expressions short-circuit the second part of the AND test would not execute since Error would not be zero. Hopefully I've explained myself adequately.
  10. Hi. Perhaps someone has already done this, but what I'm looking for is similar to the built-in command PixelSearch, but with a better ability to specify the variation. Ideally I would be able to specify separate shade-variation values for each of R, G, or B. Or perhaps even better would be able to specify variations in hue, saturation, and brightness instead (which makes more sense to me). For example, if I were looking for any color that was green, I could use values of, say, hue=0.30 to 0.36 (greenish), saturation=0 to 1 (any saturation), and brightness=0 to 1 (any brightness). Not sure how that would translate to RGB, perhaps 255, 15, 255? Anyway hopefully I've explained myself well enough. Any ideas how to go about accomplishing this? Perhaps an AutoIt Guru has already written something similar? I know I could use PixelGetColor in a loop though all pixels in the box specified by the coordinates, but, without having written the code to do that, I would suspect that performance would be terrible. Anyway, would appreciate any help. TIA
  11. OK. Thanks GS. Appreciate the reply. Have a good day.
  12. Knowing very little about APIs and DLLs and such, I have a few questions about the method you use to determine whether an app is compiled as console. How "resilient", so to speak, is this code to changes in AutoIt itself? Will this have to be modified with new releases of AutoIt? Or is it more dependent on upx, and as long as it doesn't change you'll always be looking for a D4 at offset 1000? Just curious to know when this method may "break". Thanks.
  13. Thanks GS. I never would have figured that out on my own. I'm a bit surprised there's not a built-in macro for this, however, as there's macros for almost everything else it seems. Did you already have that bit of code laying around in your toolbox, just waiting for someone to ask?
  14. In my script I would like to test to see if it was compiled using the console switch. Looking through help I see I can test whether or not the script is compiled, but I don't see a way to test for console compilation. Hopefully I'm just overlooking something obvious. So it there such a macro like @compiledConsole?
  15. In the help file it states OK, I understand that (I think) and assign my own like this:$oMyError = ObjEvent("AutoIt.Error","MyErrFunc") ; Install a custom error handlerBut now I want to set it back to "null", "empty", default, whatever. IOW if a COM error occurs the script should generate an error and end. How would I do that?
×
×
  • Create New...