Sign in to follow this  
Followers 0
JoGa

tab and _GUICtrlComboBoxEx_

4 posts in this topic

Hi,

a tabcontrol holds 2 tabs, the first containing a ComboBoxEx, the second an edit control.

When activating tab2 and moving the mouse inside the edit control, the ComboBoxEx from tab1 shows.

What am I doing wrong?

The attached example show the issue.

tab.au3

Share this post


Link to post
Share on other sites



#include <GuiConstantsEx.au3>
#include <GuiTab.au3>
#include <GuiComboBoxEx.au3>

$gui = GUICreate("Tab", 400, 200)

$tab = GUICtrlCreateTab(10, 10, 380, 180)

$t1 = GUICtrlCreateTabItem("t1")
$c1 = GUICtrlCreateCombo("", 20, 40, 300, 300)
$b1 = GUICtrlCreateButton("button", 20, 80, 60, 22)

$t2 = GUICtrlCreateTabItem("t2")
$e1 = GUICtrlCreateEdit("", 20, 40, 300, 120, 0, 0)

GUICtrlCreateTabItem("")

GUISetState()

While 1
    Switch GUIGetMsg()
        Case $GUI_EVENT_CLOSE
            Exit
    EndSwitch
WEnd

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

JoGa,

This topic will help explain. Basically (in hobbyist coder terms :( ) the _GUICtrlComboBoxEx UDF creates another window rather than a control so AutoIt treats it differently.

There are often problems when combining the UDFs with the normal built-in commands - nothing to be done about it, just learn the workarounds! :)

M23

Edit: Why use the UDF anyway - what is wrong with the built-in GUICtrlCreateCombo which does not have this problem?

Edited by Melba23

Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites

JoGa,

This topic will help explain. Basically (in hobbyist coder terms :( ) the _GUICtrlComboBoxEx UDF creates another window rather than a control so AutoIt treats it differently.

There are often problems when combining the UDFs with the normal built-in commands - nothing to be done about it, just learn the workarounds! :)

M23

Edit: Why use the UDF anyway - what is wrong with the built-in GUICtrlCreateCombo which does not have this problem?

Thanks, your link helped solving the issue.

I'm using _GUICtrlComboBoxEx because I use the _GUICtrlComboBoxEx_SetImageList() and _GUICtrlComboBoxEx_AddString() function.

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