Opened on Aug 21, 2009 at 12:19:47 PM
Last modified on Oct 10, 2009 at 2:02:43 PM
#1145 closed Bug
GUICtrlCreateTreeView() steals application focus — at Version 3
| Reported by: | tayou fabrice | Owned by: | |
|---|---|---|---|
| Milestone: | 3.3.1.2 | Component: | AutoIt |
| Version: | 3.3.1.1 | Severity: | None |
| Keywords: | Cc: | tayoufabrice tayoufabrice@… |
Description (last modified by )
The following code steals focus from the active application even though the GUI isn't visible immediately:
#cs ----------------------------------------------------------------------------
AutoIt Version: 3.3.0.0
Author: TayouFabrice
After creating a GUICtrlTreeView the GUI take focus it is a problem for an app
whish start on Background and dosn't want ot get focus before being visible
i have put sleep ( ) at line 21 to shaw that gui is not visible but has allready
focus. This problem is serious
#ce ----------------------------------------------------------------------------
#include <GUIConstantsEx.au3>
#include <TreeViewConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
$Form1 = GUICreate("Form1", 633, 447, 192, 215)
ConsoleWrite ( "> GUI is created but have no focus"&@CRLF)
Sleep ( 6000)
$TreeView1 = GUICtrlCreateTreeView(96, 32, 345, 273)
ConsoleWrite ( "> GUI has already focus"&@CRLF)
Sleep ( 6000)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
EndSwitch
WEnd
Change History (4)
follow-up: 2 comment:1 by , on Aug 21, 2009 at 5:16:46 PM
| Resolution: | → No Bug |
|---|---|
| Status: | new → closed |
comment:3 by , on Aug 21, 2009 at 7:39:34 PM
| Description: | modified (diff) |
|---|---|
| Resolution: | No Bug |
| Status: | closed → reopened |
| Summary: | activate the windows → GUICtrlCreateTreeView() steals application focus |
| Version: | 3.3.0.0 → 3.3.1.1 |
Your ticket describes activation, your example describes focus and demonstrates focus. It does demonstrate the problem for me on 3.3.1.1. Fixing the ticket to describe the problem correctly. In the future, please submit carefully written and well thought out issues with examples to avoid further hassle.
Note:
See TracTickets
for help on using tickets.

Go read WikiStart and stop wasting people's time, please. Not only did you fail to provide an example so I could show you where the problem in your code lies, you shouldn't have even been posting here in the first place.