Sign in to follow this  
Followers 0
mrbond007

ProgressBar Emulation

2 posts in this topic

#1 ·  Posted (edited)

This may not seem much but after getting tired of the default green progressbar i decided to create my own.

Here are some examples :

#include <GUIConstants.au3>
local $m = 1
GUICreate("Progress Bar", 252, 25)
GuiCtrlCreateGraphic(1, 5, 250,15)
GUICtrlSetColor(-1, 0x000000)
$ba = GuiCtrlCreateGraphic(-250, 6, 248,13)
GUICtrlSetBkColor($ba, 0x0FB1FF)
GuiSetState()

Do
    Sleep(10)
    $m = $m + 1
    GUICtrlSetPos($ba, 2, 6, $m, 13)
Until $m = 248

While 1
    $msg = GUIGetMsg()
    If $msg = $GUI_EVENT_CLOSE Then Exit
WEnd

#include <GUIConstants.au3>
local $m = 1
GUICreate("Progress Bar", 252, 25)
GuiCtrlCreateGraphic(1, 5, 250,15)
GUICtrlSetColor(-1, 0x000000)
$ba = GuiCtrlCreateGraphic(1, 6, 49,13)
GUICtrlSetBkColor($ba, 0x0FB1FF)
GuiSetState()

Do
    Sleep(10)
    $m = $m + 1
    GUICtrlSetPos($ba, $m, 6, 49, 13)
Until $m = 201

While 1
    $msg = GUIGetMsg()
    If $msg = $GUI_EVENT_CLOSE Then Exit
WEnd

#include <GUIConstants.au3>
local $m = 1
GUICreate("Progress Bar", 252, 25)
GuiCtrlCreateGraphic(1, 5, 250,15)
GUICtrlSetColor(-1, 0x000000)
$ba = GuiCtrlCreateGraphic(1, 6, 1,13)
GUICtrlSetBkColor($ba, 0x0FB1FF)
GuiSetState()

Do
    Sleep(10)
    $m = $m + 1
    GUICtrlSetPos($ba, 2, 6, $m, 13)
Until $m = 248

While 1
    $msg = GUIGetMsg()
    If $msg = $GUI_EVENT_CLOSE Then Exit
WEnd

Now you can create different shapes and colours :)

Have Fun

Edited by mrbond007

Share this post


Link to post
Share on other sites



Now you can create different shapes and colours :)

Have Fun

nice job man I was looking for this few moments ago thankx for the idea


[quote]Baby you're all that I want, When you're lyin' here in my armsI'm findin' it hard to believe, We're in heavenAnd love is all that I need , And I found it there in your heartIt isn't too hard to see, We're in heaven .Bryan Adams[/quote].............................................................................[u]AUTOIT[/u]

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