Helomotorola Posted September 5, 2007 Posted September 5, 2007 I see function API in VB very good, But I dont'n Know convert to Autoit? Please Help me! Thank much!
PsaltyDS Posted September 5, 2007 Posted September 5, 2007 I see function API in VB very good, But I dont'n Know convert to Autoit?Please Help me!Thank much!Give a short example of what you already have in VB that you want to implement in AutoIt. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Helomotorola Posted September 5, 2007 Author Posted September 5, 2007 Usually, function API in VB: Declare Function GetClassName Lib "user32" Alias "GetClassNameA" (ByVal hwnd As Long, ByVal lpClassName As String, ByVal nMaxCount As Long) As Long As: Func GetWindowClass( $hwnd ) dim $WinText $Result = DLLCall($user32, "Int", "GetClassName", "HWnd",$hwnd, "Str", $WinText, "Int", 80) Return $Result[2] EndFunc Declare Function WindowFromPoint Lib "user32" (ByVal xPoint As Long, ByVal yPoint As Long) As Long As: Func WindowFromPoint( $x,$y ) $Result = DllCall( $user32, "hwnd", "WindowFromPoint", "int",$x,"int",$y) $point = 0 Return $Result[0] EndFunc Declare Function GetParent Lib user32.dll (ByVal hwnd As Long) As Long As: Func GetParent($hwnd) $Result = DllCall( $user32, "hwnd", "GetParent", "hwnd",$hwnd) Return $Result[0] EndFunc I want Find software can convert function API of Visual Basic to function Dllcall of Autoit? Can You write? Thank!
PsaltyDS Posted September 5, 2007 Posted September 5, 2007 Usually, function API in VB: Declare Function GetClassName Lib "user32" Alias "GetClassNameA" (ByVal hwnd As Long, ByVal lpClassName As String, ByVal nMaxCount As Long) As Long As: Func GetWindowClass( $hwnd ) dim $WinText $Result = DLLCall($user32, "Int", "GetClassName", "HWnd",$hwnd, "Str", $WinText, "Int", 80) Return $Result[2] EndFunc The variable $user32 must resolve to the literal string "user32.dll". So you either need $user32 = "user32.dll", or you can drop the variable and just put "user32.dll" in there. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Helomotorola Posted September 5, 2007 Author Posted September 5, 2007 I'm sorry i using DllOpen("user32.dl") Can You hlep me do software convert API to dllcall by autoit? Thank
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now