Sign in to follow this  
Followers 0
lordicast

GuiCtrlCreateTab with images

3 posts in this topic

Is it possible to have different images on different tabs? example of code below was created with Koda but images wont show

#include <GUIConstants.au3>

#Region ### START Koda GUI section ### Form=

$Form1 = GUICreate("Tabbed Notebook Dialog", 413, 298, 303, 219)

GUISetIcon("D:05.ico")

$PageControl1 = GUICtrlCreateTab(8, 8, 396, 256)

GUICtrlSetResizing(-1, $GUI_DOCKWIDTH+$GUI_DOCKHEIGHT)

$TabSheet1 = GUICtrlCreateTabItem("TabSheet1")

$Pic1 = GUICtrlCreatePic("c:\com.bmp", 80, 96, 228, 100, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))

$TabSheet2 = GUICtrlCreateTabItem("TabSheet2")

$Pic2 = GUICtrlCreatePic("c:\help.bmp", 88, 96, 204, 100, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))

$TabSheet3 = GUICtrlCreateTabItem("TabSheet3")

$Pic3 = GUICtrlCreatePic("c:\hello.bmp", 80, 104, 209, 100, BitOR($SS_NOTIFY,$WS_GROUP,$WS_CLIPSIBLINGS))

GUICtrlCreateTabItem("")

$Button1 = GUICtrlCreateButton("&OK", 166, 272, 75, 25, 0)

$Button2 = GUICtrlCreateButton("&Cancel", 246, 272, 75, 25, 0)

$Button3 = GUICtrlCreateButton("&Help", 328, 272, 75, 25, 0)

GUISetState(@SW_SHOW)

#EndRegion ### END Koda GUI section ###

While 1

$nMsg = GUIGetMsg()

Switch $nMsg

Case $GUI_EVENT_CLOSE

Exit

EndSwitch

WEnd


[Cheeky]Comment[/Cheeky]

Share this post


Link to post
Share on other sites

Remove $WS_CLIPSIBLINGS style from pic controls.

Also, GUICtrlSetState(-1, $GUI_DISABLE) your pics if you put any other controls over them.


"be smart, drink your wine"

Share this post


Link to post
Share on other sites

thanks siao


[Cheeky]Comment[/Cheeky]

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  
Followers 0