Jump to content

[Solved] a GUI Doubt


Recommended Posts

i donno if i am flooding this forum with posts, please bear with it.

i have adoubt, i have checked few examples but they involve bit of advanced event / mouse management functions.

i have this gui

$frmMain = GUICreate("Main", 100,25,25,25,BitOR($WS_POPUP,$WS_BORDER))

i need this to be movable just like the normal window. a normal window with min, max buttons works great like any applications. but this just stays like the splash on without move control, is there any code i need to add, to make it movable?

or is there anyway i can customise the captiontitle bar of a normal window if i create it with

$frmMain = GUICreate("Main",100,25,25,25) ??

Edited by rajeshontheweb
Link to comment
Share on other sites

i donno if i am flooding this forum with posts, please bear with it.

i have adoubt, i have checked few examples but they involve bit of advanced event / mouse management functions.

i have this gui

$frmMain = GUICreate("Main", 100,25,25,25,BitOR($WS_POPUP,$WS_BORDER))

i need this to be movable just like the normal window. a normal window with min, max buttons works great like any applications. but this just stays like the splash on without move control, is there any code i need to add, to make it movable?

or is there anyway i can customise the captiontitle bar of a normal window if i create it with

$frmMain = GUICreate("Main",100,25,25,25) ??

There are several ways. Here's one

#include <windowsconstants.au3>
#include <guiconstantsex.au3>
#include <sendmessage.au3>
$frmMain = GUICreate("Test", 393, 217, -1, -1, BitOR($WS_POPUP,$WS_BORDER)),
GUISetState()

While 1
    
    $msg = GUIGetMsg()
    Switch $msg
        Case $GUI_EVENT_PRIMARYDOWN
            _SendMessage($frmMain, $WM_SYSCOMMAND, 0xF012, 0)
    EndSwitch

WEnd
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.
Link to comment
Share on other sites

will try both in a few minutes, sorry , my bad just went through a few more example scripts in the forum randomly and noticed such a good thing exists :$GUI_WS_EX_PARENTDRAG !!!

<edit> the second link is what i meant, its a bit complicated, or atleast it requires me to carefully handle all those mouse down , up events, i was looking for an safer way out - just like the above parentdrag control. anyways iwill start using keyboard / mouse handling functions soon. :-)

will try first one shortly..<edit> so , i can get away with it by registering only one command , the WM_SYSCommand? thanks a lot mate. i will use this along with the title parentdrag which will enable me to ad the minimise and close controls also

Edited by rajeshontheweb
Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...