Jump to content
Sign in to follow this  

GUI with title and minimise only

Recommended Posts


I want to create a GUI window with a title up against the left of the title bar (no icon) and a minimise icon on the right. (An icon must display in the system tray).

I have been able to create a GUI with an icon on the left and a close icon on the right.

I found some other resources on this forum and they explained how to make the close icon minimise instead of close as follows:

$msg = GUIGetMsg()


case $msg = $GUI_EVENT_CLOSE



1. I assume that there is some way to change the graphic by using GUICtrlSetGraphic, but Ihaven't been able to find the control id that I should use. Is there a control ID that will allow this?

2. Also I haven't been able to get rid of the left hand icon. Is there some way to do this?

3. Also I want this window to 'hug' a 100 x 100 jpg image I seem to be able to size the window correctly in the Y plane, but I can't seem to get it smaller than about 130 in the X plane.

One of the many create GUI commands that I have tried is:

$WinStyle = 0x00080000


Why do I want to do this?

The script sits in the system tray until a named window is open, and then parses text from that window to determine a photo to display in front of all other windows. While the named window is open the photo is visible, but if the named window is closed or doesn't have a valid photo, the photo window becomes hidden and is only visible in the system tray (so that the user can exit if necessary). If the user finds the photo is in the way the user should be able to minimise the window, but not accidentaly exit the script. The compiled script will be started automaticaly when the workstation is started.

Please note the grey stripe down the right where the window is too big so the background grey shows through.


Edited by kschwart

Share this post

Link to post
Share on other sites

guictrlsetgrapic is used with the graphic control(guictrlcreategraphic)

OK - So do you know if there is there a way to replace the close button icon on the GUI?

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