Jump to content

Gui Question About Forms


Recommended Posts

In one of the sample scripts for au3 there is a tidbit of code that apparently uses Notepad for a form gui instead of the normal windows form gui. It's

Au3GUIFormColor(0x00E0FFFF) and I was curious to know if anyone else knows of a way to use a variation of this code or another code to use a JPG as a background for a form instead of just a solid hex color or the gray windows form background?

I have played around with SplashImageOn but have not had any luck with it. I am currently using the AU3 version 3.0.102.13 unstable version. If there is a diffrent version that can use JPG as a background on a form I would change my version of AutoIt.

I have set out to understand the obscure :D

Link to comment
Share on other sites

Any functions that begin with "Au3GUI" are probably old and will not work with the current GUI implementation.

Since previous posts indicate you are using the latest unstable AutoIt version, try GUISetControl("pic", ....

Hope that helps

Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Link to comment
Share on other sites

I found the section in the help file that refrences GUISetControl("pic", but I couldn't find a refrence on how to set what picture it should use. Say I want a form with a picture called picture.jpg that is located in C:\pictures, when AutoIt creates the gui form it should be 100 wide and 75 high. Can you give me a more workable code for this as a pointer or would it be easier to revert back to v3.0.101? If so, what about a code for a working example with the above parameters for it?

Thanks in advance for input

Link to comment
Share on other sites

Sure :D

GuiCreate("MyGUI") ;optionally specify window position and size and style
GuiSetControl("pic", "C:\pictures\picture.jpg", 0, 0, 100, 75);left,top,width,height

; One typical message loop I use; display GUI until user clicks the 'x' close button
GuiShow()
While GuiMsg(0) <> -3 
    sleep(100)
WEnd
Exit

Although you should avoid overlapping controls, I've discovered pictures always appear behind other controls (except for tab controls).

Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
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...