Sign in to follow this  
Followers 0
brawl

gui windows

8 posts in this topic

i made a gui that has a gui inside it. and whenever i move the gui i want the one inside it to stay where it is (not move). the small gui inside my bigger gui is the child gui.

im new and dont know much so if you could please help me i'd appreciate it.

Share this post


Link to post
Share on other sites



Ok, but how can I get the title bar to disappear?

Share this post


Link to post
Share on other sites

If you remove the title bar, how do you move the window?

#include <GuiConstants.au3>

$MainGUI = GUICreate("Main GUI", 300, 200)
GUISetState()

$ChildGUI = GUICreate("Child GUI", 200, 100, -1, -1, $WS_BORDER+$WS_POPUP, -1, $MainGUI)
GUISetState()

Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE

Share this post


Link to post
Share on other sites

I'm not sure...I was hoping someone could help me with that. :)

Share this post


Link to post
Share on other sites

If you remove the title bar, how do you move the window?

Various ways, here's one

#include <GuiConstants.au3>

$MainGUI = GUICreate("Main GUI", 300, 200)
GUISetState()

$ChildGUI = GUICreate("Child GUI", 200, 100, -1, -1, $WS_BORDER + $WS_POPUP, -1, $MainGUI)
GUISetState()
GUIRegisterMsg($WM_NCHITTEST, "WM_NCHITTEST")
Do
Until GUIGetMsg() = $GUI_EVENT_CLOSE

Func WM_NCHITTEST($hWnd, $iMsg, $iwParam, $ilParam)
    If $hWnd = $ChildGUI And $iMsg = $WM_NCHITTEST Then
        $id = _API_DefWindowProc($hWnd, $iMsg, $iwParam, $ilParam)
        $mi = GUIGetCursorInfo($ChildGUI)
        If $id = 1 Then;if it is the client handle
            Return 2;return the title handle
        Else
            Return $id;return the real handle
        EndIf
    EndIf

EndFunc  ;==>WM_NCHITTEST


Func _API_DefWindowProc($hWnd, $iMsg, $iwParam, $ilParam)
    Local $aResult

    $aResult = DllCall("User32.dll", "int", "DefWindowProc", "hwnd", $hWnd, "int", $iMsg, "int", $iwParam, "int", $ilParam)
    Return $aResult[0]
EndFunc  ;==>_API_DefWindowProc

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

#7 ·  Posted (edited)

That't not working... :)

Btw: I have beta.

Edited by brawl1

Share this post


Link to post
Share on other sites

This user has been banned repeatedly... (aka Firelord and others).


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  
Followers 0