Hi,
habs so gelöst...
Spoiler anzeigen
#include <ComboConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
global $hidden
global $main = GUICreate("AutoITDeskBar2",@DesktopWidth +2,70,-2,-30, $WS_BORDER , $WS_EX_APPWINDOW )
dim $pos[4]=[0,1,2,3]
$Combo1 = GUICtrlCreateCombo("Projekte", @DesktopWidth - 300, 8, 193, 25,$CBS_DROPDOWNLIST)
GUICtrlSetData(-1, "item2|item3|ee|rr|ttt|ttt|www|qqq", "item3")
$Beende = GUICtrlCreateButton("Beende", @DesktopWidth - 80, 8, 75, 25, $WS_GROUP)
GUISetState(@SW_SHOW)
$tPos = WinGetPos($main)
While 1
$mPos = MouseGetPos()
if $hidden =false Then
$pos = ControlGetPos("[CLASS:ComboLBox; INSTANCE:1]","","") ;daten von der combobox holen
if @error<>1 then
consolewrite($pos[0]&" "&$pos[1]&" "&$pos[2]&" "&$pos[3]&@crlf) ;x,y, breite, hoehe
$mouseposallowed=0
If $mpos[0]<$pos[0] and $mpos[1]>70 then $mouseposallowed=1 ;links von der combo und unterhalb vom fenster
if $mpos[1]>$pos[3] +20 then $mouseposallowed=1 ;unterhalb der combo
if $mpos[0]>$pos[0]+$pos[2] and $mpos[1]>70 then $mouseposallowed=1 ;rechts von combo und unterhalb vom fenster
endif
endif
If WinActive("AutoITDeskBar2") = 0 And $hidden And $mPos[1]<2 Then
WinActivate($main)
WinSetState($main,"",@SW_SHOW)
$hidden = False
ElseIf Not $hidden And $mouseposallowed Then
WinSetState($main,"",@SW_HIDE)
$hidden = True
EndIf
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
exit
EndSwitch
;if $nmsg<>0 then consolewrite($nmsg&@crlf)
WEnd
ciao
Andy