Sign in to follow this  
Followers 0
mapet

How can i find ControlID ?

10 posts in this topic

How can a get the ControlID from a MDI Window? Is there any function to get this ControlID from the active, focused window?

I need this ControlID for using : ControlFocus ("BlaBla", "", "[iD:" & $ControlID & "; INSTANCE:1]") ....

Mapet

Share this post


Link to post
Share on other sites



How can a get the ControlID from a MDI Window? Is there any function to get this ControlID from the active, focused window?

I need this ControlID for using : ControlFocus ("BlaBla", "", "[iD:" & $ControlID & "; INSTANCE:1]") ....

Mapet

Hi,

1. Autoit Window Info Tool

2. Try without ControlID

Mega


Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Share this post


Link to post
Share on other sites

Use the AutoIT Window Info tool that comes with AutoIT.


[sub]Quantum mechanics: The dreams stuff is made of[/sub]

Share this post


Link to post
Share on other sites

Use the AutoIT Window Info tool that comes with AutoIT.

Sorry, the application can creat many Cildwindows and do not know the correct number of Windows.

So i need a funktion to get the ControlId, so i can read check the Titel an can remember the controlID.

In the next step i can use ControlFocus to bring the right window into th front. Then i can send my information to this Window ....

mapet

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

1. Autoit Window Info Tool

2. Try without ControlID

1. Sorry, the application creats many Child windows, and i do not know how many. So i must Scan the windows using send(TAB) and so...

2. how ? i want to scan all windows an want to learn the windows, so i can ControlFocus to bring a spez. window to the front into the focus ....

Thx. Mapet

Edited by mapet

Share this post


Link to post
Share on other sites

How can a get the ControlID from a MDI Window? Is there any function to get this ControlID from the active, focused window?

I need this ControlID for using : ControlFocus ("BlaBla", "", "[iD:" & $ControlID & "; INSTANCE:1]") ....

Mapet

You must use EnumChildWindows API with CallBack function.

Look at example for DllCallbackRegister() in AutoIt helpfile.

Share this post


Link to post
Share on other sites

You must use EnumChildWindows API with CallBack function.

Look at example for DllCallbackRegister() in AutoIt helpfile.

Sorry, i am a absolut beginner with AutoIT. Any exampe for me ?

Mapet

Share this post


Link to post
Share on other sites

Sorry, i am a absolut beginner with AutoIT. Any exampe for me ?

Mapet

Zedna told you where to find an example, so you need to explain what you don't understand about what Zedna said.

Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.

Share this post


Link to post
Share on other sites

Zedna told you where to find an example, so you need to explain what you don't understand about what Zedna said.

Sorry, i look in the example of: DllCallbackRegister

; Create callback function

$handle = DLLCallbackRegister ("_EnumWindowsProc", "int", "hwnd;lparam")

DllCall("user32.dll", "int", "EnumWindows", "ptr", DllCallbackGetPtr($handle), "lparam", 10)

DllCallbackFree($handle)

Func _EnumWindowsProc($hWnd, $lParam)

If WinGetTitle($hWnd) <> "" And BitAnd(WinGetState($hWnd), 2) Then

$res = MsgBox(1, WinGetTitle($hWnd), "$hWnd=" & $hWnd & @CRLF & "lParam=" & $lParam & @CRLF & "$hWnd(type)=" & VarGetType($hWnd))

If $res = 2 Then Return 0 ; Cancel clicked, return 0 to stop enumeration

EndIf

Return 1 ; Return 1 to continue enumeration

EndFunc

But i can not see a solution for my problem.

i am looking for:

- scann all open ChildWindows of a MDI Application

- set focus to special ChildWindows out of the list ....

Need help: How can i get the ContolId dynamic in my script ????

Mapet

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0