It is currently Thu Nov 23, 2017 11:58 am

All times are UTC + 1 hour




Post new topic Reply to topic  [ 48 posts ]  Go to page Previous  1, 2, 3, 4  Next
Author Message
 Post subject: Re: AutoWin UserLibrary
PostPosted: Mon Jan 30, 2012 12:19 am 
Offline
Addict
Addict
User avatar

Joined: Thu Jun 07, 2007 3:25 pm
Posts: 3142
Location: Berlin, Germany
ts-soft wrote:
Thx for bugreport. Download the fixed version in first post!

Thanks.

ts-soft wrote:
PS: AW_FindWindow is not a public function :mrgreen:

I had a program that called the following public procedures:
Code:
AW_ChangeMatchMode(#AW_MatchParaIsHwnd)
AW_WinWaitClose(Str(hWnd))

The program never ended, because AW_WinWaitClose() never ended, even when the respective window was closed. The cause of the problem was the bug in AW_FindWindow(), which is called by AW_WinWaitClose().
I only called AW_FindWindow() directly in my example code here in order to clearly demonstrate the bug.

Regards, LJ

_________________
Please excuse my flawed English. My native language is PureBasic.
Search
RSBasic's backups


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Thu Jan 29, 2015 3:13 pm 
Offline
Enthusiast
Enthusiast

Joined: Tue Aug 05, 2003 11:30 pm
Posts: 435
Is there a version of this lib for actual PB version?
If i use the lib with PB 5.31 i receive many error message and i can't compile the code. what includes Au3Wrap.pbi.

Thanks,
Nico

_________________
my live space


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Thu Jan 29, 2015 6:22 pm 
Offline
Always Here
Always Here
User avatar

Joined: Thu Jun 24, 2004 2:44 pm
Posts: 5726
Location: Berlin - Germany
The code compiles fine with 5.31, as include. I can't find any error.
To compile as tailbites userlib (not recommend), you have to use a compatible
version of tailbite.
There is no Au3Wrap.pbi in download, have you the right package?

_________________
PureBasic 5.61 | SpiderBasic 2.10 | Windows 10 Pro (x64) | Linux Mint 18.2 (x64)
I would like to change the world, but God does not release the source code.
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Apr 18, 2015 11:15 am 
Offline
User
User

Joined: Mon May 05, 2014 6:51 pm
Posts: 23
ts-soft wrote:
The code compiles fine with 5.31, as include. I can't find any error.

Hi
I have copied AutoWin (Version 1.4.1) lib to C:\PureBasic\PureLibraries\UserLibraries
I tried to compile and get this error: "Library missing: Misc (needed by 'AutoWin' library)."
please help
thanks
ly
[code]
EnableExplicit

Define.s Title
RunProgram("notepad")

Select GetUserDefaultLCID_()
Case 1031; german
Title = "Unbenannt"
Default
Title = "Untitled"
EndSelect
If AW_WinWait(Title, 10)
AW_WinActivate(Title)
AW_SendKeys("Feel the ..Pure.. Power{ENTER}{ENTER}of PureBasic.")
Delay(3000)
AW_WinActivate(Title)
AW_SendKeys("{ALTDOWN}{F4}{ALTUP}")
Delay(3000)
If AW_WinExists(Title)
AW_WinKill(Title)
EndIf
EndIf
/code]


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Apr 18, 2015 12:02 pm 
Offline
Addict
Addict
User avatar

Joined: Thu Jun 07, 2007 3:25 pm
Posts: 3142
Location: Berlin, Germany
Your code does not contain (X)IncludeFile for including the AutoWin library.

ts-soft wrote:
To compile as tailbites userlib (not recommend), you have to use a compatible
version of tailbite.

( And improving the readability by putting the code in proper [ code ] tags will help others to help you. )

_________________
Please excuse my flawed English. My native language is PureBasic.
Search
RSBasic's backups


Last edited by Little John on Sat Apr 18, 2015 1:59 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Apr 18, 2015 1:36 pm 
Offline
Always Here
Always Here

Joined: Fri Oct 23, 2009 2:33 am
Posts: 5687
Location: Wales, UK
Well, the error message says it can't find the Misc lib, which suggests that the AutoWin lib includes a procedure found in Misc?
Is that an issue caused by using TailBite? I seem to recall that from way back when.

ly47, if you are using TailBite, try an XIncludeFile of AutoWin_Include.pbi instead.

_________________
IdeasVacuum
If it sounds simple, you have not grasped the complexity.


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Apr 18, 2015 5:18 pm 
Offline
User
User

Joined: Mon May 05, 2014 6:51 pm
Posts: 23
IdeasVacuum wrote:
Well, the error message says it can't find the Misc lib, which suggests that the AutoWin lib includes a procedure found in Misc?
Is that an issue caused by using TailBite? I seem to recall that from way back when.

ly47, if you are using TailBite, try an XIncludeFile of AutoWin_Include.pbi instead.


Hi IdeasVacuum
Thanks
I have delete AutoWin (Version 1.4.1) lib (from C:\PureBasic\PureLibraries\UserLibraries), and used XIncludeFile of AutoWin_Include.pbi instead, and it works.
But not all procedures are working.
(ie: AW_WinMove, AW_WinActivate, AW_WinWait)
I have modified the code so only SendKeys works.
Thanks
ly

Code:
Define.s Title, myTitle
Define.i dly = 1111

RunProgram("notepad")

Define.i lcid

; lcid = GetUserDefaultLCID_()
; Debug Str(lcid)

Select GetUserDefaultLCID_()
  Case 1031; german
    Title = "Unbenannt"
  Default
    Title = "Untitled - Notepad"
EndSelect

; If AW_WinWait(Title,10)
;    AW_WinActivate(Title)
;    myTitle = AW_WinGetTitle2(Title)
;    Debug myTitle
    Delay(dly)
;    AW_WinMove(Title, 10, 10)

    Delay(dly)
   AW_SendKeys("Feel the ..Pure.. Power{ENTER}{ENTER}of PureBasic.")
   Delay(dly)
;    AW_WinActivate(Title)
;    Delay(dly)
   AW_SendKeys("{ALTDOWN}{F4}{ALTUP}")
   Delay(dly)
   AW_SendKeys("{TAB}")
   Delay(dly)
   AW_SendKeys("{ENTER}")
;    If AW_WinExists(Title)
;       AW_WinKill(Title)
;    EndIf
; EndIf


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Tue Apr 21, 2015 6:27 am 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Fri Jun 30, 2006 4:30 pm
Posts: 578
Location: Middle East
Thanks for this nice library ts-soft

I modified the AW_ControlClick to support custom coordinates like Autoit ControlClick

Code:

Macro AW_ControlClick(title, controlID, Button = #PB_Button_Left, clicks = 1, x = -1, y = -1)
  AW_ControlClick3(title, controlID, Button, clicks, x, y)
EndMacro

Macro MAKELPARAM(x, y)
  (y<<16) | x
EndMacro

ProcedureDLL AW_ControlClick3(title.s, controlID.s, Button, clicks, x, y)
  Protected i
  Protected *param.AW_WinParameter

  *param = AW_FindWindow(title)
  If *param\hWnd
    *param = AW_FindControl(*param\hWnd, controlID.s)
    If *param\hWnd
      Select Button
        Case #PB_Button_Left
          For i = 1 To clicks
            If x > -1 And y > -1
              PostMessage_(*param\hWnd, #WM_LBUTTONDOWN, 0, MAKELPARAM(x, y))
                  PostMessage_(*param\hWnd, #WM_LBUTTONUP, 0, MAKELPARAM(x, y))
               Else
                  PostMessage_(*param\hWnd, #WM_LBUTTONDOWN, 0, 0)
                  PostMessage_(*param\hWnd, #WM_LBUTTONUP, 0, 0)
               EndIf
            If i < clicks
              Delay(GetDoubleClickTime_())
            EndIf
          Next
          ProcedureReturn #True
        Case #PB_Button_Right
          For i = 1 To clicks
            If x > -1 And y > -1
              PostMessage_(*param\hWnd, #WM_RBUTTONDOWN, 0, MAKELPARAM(x, y))
              PostMessage_(*param\hWnd, #WM_RBUTTONUP, 0, MAKELPARAM(x, y))
               Else
              PostMessage_(*param\hWnd, #WM_RBUTTONDOWN, 0, 0)
              PostMessage_(*param\hWnd, #WM_RBUTTONUP, 0, 0)
            EndIf
            If i < clicks
              Delay(GetDoubleClickTime_())
            EndIf
          Next
          ProcedureReturn #True
      EndSelect
    EndIf
  EndIf
EndProcedure

_________________

[Registered PB User since 2006]
[PureBasic 5.5] [Win 10 64bit]
[Intel i7 990x 3.47 Ghz] [18GB DDR3]


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sun Oct 11, 2015 11:25 am 
Offline
User
User

Joined: Mon Dec 24, 2012 9:07 am
Posts: 11
Location: Ukraine, Donetck
Hello all!
Help me please,
what activate mouseclick with global hotkeys?
I automation vst synth, and can't control the mouse with keyboard.

_________________
Sory my bad english
Death of Russian invaders, freedom Donetck!


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Tue Oct 13, 2015 6:03 pm 
Offline
Enthusiast
Enthusiast

Joined: Tue Oct 14, 2014 12:09 pm
Posts: 177
Hi Ts_soft
Can you help meon how to do an obj file with autoitx.dll to and tailbite. I want to adapt your library to PB 5.40
Thanks in advance


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Fri Aug 11, 2017 6:02 pm 
Offline
New User
New User

Joined: Fri Aug 11, 2017 5:54 pm
Posts: 2
Hallo Thomas alias TS-Soft,

besteht die Möglichkeit, dass Du für AutoWin eine UserLibrary erstellst, die mit der aktuellen Purebasic -Version arbeitet?

Nette Grüße
Christian


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Fri Aug 11, 2017 6:10 pm 
Offline
Moderator
Moderator
User avatar

Joined: Thu Dec 31, 2009 11:05 pm
Posts: 377
Location: Berlin and Ibiza
@Pasch3
Am besten stellt er den Quellcode als Include zur Verfügung. Das wäre am besten. Dann kannst auch du den Code auf die neuste PB-Version anpassen, falls sich die Syntax einer Funktion o.ä. ändern sollte.

_________________
ImageImageImageImage


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Aug 12, 2017 10:35 am 
Offline
Addict
Addict
User avatar

Joined: Thu Jun 07, 2007 3:25 pm
Posts: 3142
Location: Berlin, Germany
Pasch3 wrote:
Hallo Thomas alias TS-Soft,

besteht die Möglichkeit, dass Du für AutoWin eine UserLibrary erstellst, die mit der aktuellen Purebasic -Version arbeitet?

(asking ts-soft for creating an AutoWin userlib that is compatible with the current PB version)

ts-soft wrote:
compile as tailbites userlib (not recommend)

Not recommending this is a good advice.

_________________
Please excuse my flawed English. My native language is PureBasic.
Search
RSBasic's backups


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Aug 12, 2017 11:27 am 
Offline
User
User

Joined: Tue Jun 17, 2014 4:49 pm
Posts: 39
Where is the download link for this library?

The link in the very first posting leads to: http://realsource.de/?page_id=9999999


Top
 Profile  
Reply with quote  
 Post subject: Re: AutoWin UserLibrary
PostPosted: Sat Aug 12, 2017 11:52 am 
Offline
Addict
Addict
User avatar

Joined: Thu Jun 07, 2007 3:25 pm
Posts: 3142
Location: Berlin, Germany
Hi,

maybe RSBasic has it in his archive ... I don't know.
Anyway, you can now download the original AutoWin_1.4.1.zip file (including source code) from my Dropbox.

_________________
Please excuse my flawed English. My native language is PureBasic.
Search
RSBasic's backups


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 48 posts ]  Go to page Previous  1, 2, 3, 4  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye