Jump to content

hmmm GUI GUICtrlCreateTabItem


Recommended Posts

ok im stumped

#include <GUIConstants.au3>
GUICreate("test", 622, 424, 192, 125)
GUICtrlCreateTab(0, 0, 625, 25)
GUICtrlCreateTabItem("open")
GUICtrlCreateTabItem("close")
GUISetState(@SW_SHOW)
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case Else
        ;my code  :D 
    EndSelect
WEnd
Exit

so how do i add a button in each colum, i wouldn't be asking but im not at my house. lol you might be thinking how i came up with this code with out the help file then. well its pretty simple, i like making GUI's so i always remember the starting of a gui, and i always doodle a gui well im bored and the CtrlCreateTabItem

came to mind becuase i never made one with the option before so i wanted to try it.

[s]Autoit[/s]
Link to comment
Share on other sites

Like this :D

#include <GUIConstants.au3>
GUICreate("test", 622, 424, 192, 125)
GUICtrlCreateTab(0, 0, 625, 25)
GUICtrlCreateTabItem("open")
$Button1 = GUICtrlCreateButton("Button1", 100, 100)
GUICtrlCreateTabItem("close")
$Button2 = GUICtrlCreateButton("Button2", 100, 100)
GUISetState(@SW_SHOW)
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case Else
        ;my code  biggrin.gif
    EndSelect
WEnd
Exit

Don't take my pic to serious...~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~You Looked, but you did not see!~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Link to comment
Share on other sites

Like this :D

#include <GUIConstants.au3>
GUICreate("test", 622, 424, 192, 125)
GUICtrlCreateTab(0, 0, 625, 25)
GUICtrlCreateTabItem("open")
$Button1 = GUICtrlCreateButton("Button1", 100, 100)
GUICtrlCreateTabItem("close")
$Button2 = GUICtrlCreateButton("Button2", 100, 100)
GUISetState(@SW_SHOW)
While 1
    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
        ExitLoop
    Case Else
        ;my code  biggrin.gif
    EndSelect
WEnd
ExitoÝ÷ Ûú®¢×8¸¤ì"¶¶Þ²¶§ØZ¶È¦¦W¢Á«)­ëmÊË«z+p¢é]më(ëax%G­+³¥«­¢+Ø¥¹±Õ±ÐíU%
½¹ÍѹÑ̹ÔÌÐì)U%
ÉÑ ÅÕ½ÐíÑÍÐÅÕ½Ðì°ØÈÈ°ÐÈаÄäÈ°ÄÈÔ¤)U%
Ñɱ
ÉÑQ À°À°ØÈÔ°ÈÔ¤(ÀÌØíÑÄôU%
Ñɱ
ÉÑQ%Ñ´ ÅÕ½Ðí½Á¸ÅÕ½Ðì¤(ÀÌØíÑÅÕÑѽ¸ôU%
Ñɱ
ÉÑ    ÕÑѽ¸ ÅÕ½Ðí   ÕÑѽ¸ÄÅÕ½Ðì°ÄÀÀ°ÄÀÀ¤(ÀÌØíÑÈôU%
Ñɱ
ÉÑQ%Ñ´ ÅÕ½Ðí±½ÍÅÕ½Ðì¤(ÀÌØíÑÉÕÑѽ¸ôU%
Ñɱ
ÉÑ    ÕÑѽ¸ ÅÕ½Ðí   ÕÑѽ¸ÈÅÕ½Ðì°ÄÀÀ°ÄÀÀ¤)U%MÑMÑÑ¡M]}M!=¤)]¡¥±Ä(ÀÌØíµÍôÕ¥Ñ5Í ¤(M±Ð(
ÍÀÌØíµÍôÀÌØíU%}Y9Q}
1=M(á¥Ñ1½½À(
ͱÍ(íµä½¥É¥¸¹¥(¹M±Ð)]¹)á¥

thanks

Edited by Vicks
[s]Autoit[/s]
Link to comment
Share on other sites

well im here i know how to make a slider but, how do you make a slider going upwards? thanks

Use style $TBS_Vert, demo by minimal changes to the help file example:

#include <GUIConstants.au3>

GUICreate("slider", 220, 300, 100, 200)
GUISetBkColor(0x00E0FFFF)  ; will change background color

$slider1 = GUICtrlCreateSlider(10, 10, 30, 200, BitOr($GUI_SS_DEFAULT_SLIDER,$TBS_VERT))
GUICtrlSetLimit(-1, 200, 0)   ; change min/max value
$button = GUICtrlCreateButton("Value?", 75, 70, 70, 20)
GUISetState()
GUICtrlSetData($slider1, 45) ; set cursor

$start = TimerInit()
Do
    $n = GUIGetMsg()
    
    If $n = $button Then
        MsgBox(0, "slider1", GUICtrlRead($slider1), 2)
        $start = TimerInit()
    EndIf
Until $n = $GUI_EVENT_CLOSE

Note that I think there's a typo in the help file for slider styles. The definition of $TBS_Vert in the above link says:

Places ticks on the left side of a vertical trackbar.

I think that was a misplace copy/paste, and it meant to say:

Specifies a vertical trackbar.

:D
Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
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...