Jump to content

Auto3Lib


PaulIA
 Share

Recommended Posts

Have you tried using _GUICtrlTreeView_GetChecked , _GUICtrlTreeView_SetChecked?

I tried those routines, and I know get an exception from the C# Example application that I'm trying to work with.

I have attached an archive with the application that I am trying to use. I use "Form1" for the Window Title Value, "blah" from the Text Box for the Window Unique Text, "WindowsForms10.SysTreeView32.app.0.378734a1" for the Control Name, "Node0" for the Node Name that I want to either Check, or Uncheck.

I'm simply trying to get a Node to Check, Uncheck, or Toggle. That's it. Any help is appreciated.

TreeViewWithCheckBoxesExample.zip

Link to comment
Share on other sites

with 3.2.9.3 Beta

>"C:\Program Files\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /prod /AU3Check /in "C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3"
+>11:40:55 Starting AutoIt3Wrapper v.1.9.3
>Running AU3Check (1.54.9.0)  from:C:\Program Files\AutoIt3
C:\Program Files\AutoIt3\Include\Structures.au3(1454,60) : ERROR: $tagNMHDR previously declared as a 'Const'
Global Const $tagNMHDR = "int hWndFrom;int IDFrom;int Code"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\Structures.au3(1480,39) : ERROR: $tagPOINT previously declared as a 'Const'
Global Const $tagPOINT = "int X;int Y"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\Structures.au3(1492,64) : ERROR: $tagRECT previously declared as a 'Const'
Global Const $tagRECT = "int Left;int Top;int Right;int Bottom"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\Structures.au3(1502,38) : ERROR: $tagSIZE previously declared as a 'Const'
Global Const $tagSIZE = "int X;int Y"

and more...

Link to comment
Share on other sites

with 3.2.9.3 Beta

>"C:\Program Files\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /prod /AU3Check /in "C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3"
+>11:40:55 Starting AutoIt3Wrapper v.1.9.3
>Running AU3Check (1.54.9.0)  from:C:\Program Files\AutoIt3
C:\Program Files\AutoIt3\Include\Structures.au3(1454,60) : ERROR: $tagNMHDR previously declared as a 'Const'
Global Const $tagNMHDR = "int hWndFrom;int IDFrom;int Code"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\Structures.au3(1480,39) : ERROR: $tagPOINT previously declared as a 'Const'
Global Const $tagPOINT = "int X;int Y"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\Structures.au3(1492,64) : ERROR: $tagRECT previously declared as a 'Const'
Global Const $tagRECT = "int Left;int Top;int Right;int Bottom"
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\Structures.au3(1502,38) : ERROR: $tagSIZE previously declared as a 'Const'
Global Const $tagSIZE = "int X;int Y"

and more...

Did you download the zip I provided?

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

Did you download the zip I provided?

with same C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3

with zip

>"C:\Program Files\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3" /autoit3dir "C:\Program Files\AutoIt3" /UserParams    
+>12:50:22 Starting AutoIt3Wrapper v.1.9.3
>Running AU3Check (1.54.9.0)  from:C:\Program Files\AutoIt3
C:\Program Files\AutoIt3\Include\A3LSecurity.au3(399,46) : WARNING: $ERROR_NO_TOKEN: possibly used before declaration.
    if _API_GetLastError() = $ERROR_NO_TOKEN then
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\A3LSecurity.au3(448,70) : WARNING: $SE_PRIVILEGE_ENABLED: possibly used before declaration.
    $iAttributes = BitOR ($iAttributes,        $SE_PRIVILEGE_ENABLED )
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\A3LSecurity.au3(399,46) : ERROR: $ERROR_NO_TOKEN: undeclared global variable.
    if _API_GetLastError() = $ERROR_NO_TOKEN then
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3 - 1 error(s), 2 warning(s)
!>12:50:24 AU3Check ended.rc:2
+>12:50:26 AutoIt3Wrapper Finished
>Exit code: 0    Time: 3.668

thx.

Link to comment
Share on other sites

with same C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3

with zip

>"C:\Program Files\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.exe" /run /prod /ErrorStdOut /in "C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3" /autoit3dir "C:\Program Files\AutoIt3" /UserParams    
+>12:50:22 Starting AutoIt3Wrapper v.1.9.3
>Running AU3Check (1.54.9.0)  from:C:\Program Files\AutoIt3
C:\Program Files\AutoIt3\Include\A3LSecurity.au3(399,46) : WARNING: $ERROR_NO_TOKEN: possibly used before declaration.
    if _API_GetLastError() = $ERROR_NO_TOKEN then
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\A3LSecurity.au3(448,70) : WARNING: $SE_PRIVILEGE_ENABLED: possibly used before declaration.
    $iAttributes = BitOR ($iAttributes,        $SE_PRIVILEGE_ENABLED )
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Include\A3LSecurity.au3(399,46) : ERROR: $ERROR_NO_TOKEN: undeclared global variable.
    if _API_GetLastError() = $ERROR_NO_TOKEN then
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
C:\Program Files\AutoIt3\Auto3Lib\GDI+\Clock.au3 - 1 error(s), 2 warning(s)
!>12:50:24 AU3Check ended.rc:2
+>12:50:26 AutoIt3Wrapper Finished
>Exit code: 0    Time: 3.668oÝ÷ ÚØqþ«¨µäëɧ]x-¡«­¢+Ø¥¹±Õ±ÐíMÕÉ¥Ñå
½¹ÍѹÑ̹ÔÌÐì

to A3LSecurity.au3

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

PaulIA:

I cannot install these functions because it reads my self-installed (zip installation) as auto-it version 0.

Requiring a version check that depends on something in the registry is not the best, IMO, but I used the fix provided in the first post and it worked.

Edited by Blue_Drache

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

Link to comment
Share on other sites

I imagine some more of this will be broken pretty soon.

I've decided I'm not going to try to keep this up to date.

To much to do with the bug fixes/addtions to the UDFs included with the AutoIt install.

Gary

Edited by GaryFrost

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

So let me know if I'm understanding this right... All (or most of) AutoItLib is being incorporated into AutoIt (currently just the beta version I think). Is that right?

Slowly but surely yes, until it becomes a release version....

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

Hello,

I am using the _ScreenCap_Capture function from Auto3Lib to take screen shots of what my script is doing, and after almost 5000 screen shots taken the following error message is generated: "_API_CreateCompatibleDC.The operation completed successfully."

When I tried to take a screen shot with this error message (using Print Screen), another error is displayed: "Insufficient memory to create bitmap. Close one or more applications to increase available."

After I closed the error message I was able to take screen shots without any problem.

I have taken 2 photos with my mobile phone, but I don't know how to upload them to this post :-(.

I tried to reproduce it to my laptop, but without any luck.

I wrote a small script, and run it on the computer where it appeared. I opened the Task Manager, and took screen shots with it. After 4979 pictures take the error appeared again.

#include <A3LScreenCap.au3>

Local $_stepNumber

$_stepNumber = 1

While 1
    If MouseGetPos(0) == 280 Then
        MouseMove(380, 203)
    Else
        MouseMove(280, 203)
    EndIf
    MouseClick("left")
    _ScreenCap_Capture("Test_" & $_stepNumber & "_" & @HOUR & "-" & @MIN & "-" & @SEC &  ".jpg")
    Sleep(5000)
    $_stepNumber += 1
WEnd

The same behavior appears on 3 computers that had the same OS image.

If you need any other info about this please let me know.

Thanks,

Alex

Link to comment
Share on other sites

  • Moderators

I'm surprised you got that many without a recurssion error.

The very end of _ScreenCap_Capture() should at the very least be:

Local iSSImage = _ScreenCap_SaveImage($sFileName, $hBMP)
  SetError(@error, @extended, iSSImage)
  _API_DeleteObject($hBMP)
  Return
EndFunc
Although that whole function needs a bit of re-thinking, I know when I save a file, I may still want to work with the bmp... so it should return the bmp after the save, and the user be responsible for deleting the object. Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...