Find Code:
All Words
Any of the Words
Exact Phrase
Home
:
Code
:
Forums
:
Submit
:
Mailing List
:
About
:
Contact
Code
All
VB.NET
ASP.NET
C#
VB Classic
ASP Classic
Snippets
Popular
Resources
Submit Code
Forums
Articles
Tips
Links
Books
Contest
Link to us
This demonstrates an image control behaving like a...
Author:
2fried2code
E-mail:
Click to e-mail author
Submitted:
9/23/2000
Version:
VB6
Compatibility:
VB6
Category:
ActiveX
Views:
8819
This demonstrates an image control behaving like a progress bar.
Declarations:
'none
Code:
Private Sub Form_Load() 'put 4 textboxes on a form ' put one image control and load a picture into it chopwatch = Val(Text1) ' text1 is the seconds duration Start = Timer Text2 = Text1 Do While Timer < Start + chopwatch DoEvents Form1.Show Text1 = (Val(Text2)) - Val(Text3) Text3 = Str(Val(Timer - Start)) & " " & "Seconds" Textpercent = Val(Text3) / Val(Text2) * 100 ' this controls progress imagebar statI.Width = (Val(Textpercent) * ((Text2.Width / 100) - 0.33)) ' this is the image stretched to fit ' to text2's width the .33 is a stretch adjustment Loop End Sub
Home
|
Forums
|
Submit
|
Books
|
Mailing List
|
Advertising
|
About
|
Contact
© 2024 A1VBCode. All rights reserved.
Legal disclaimer & terms of use
Privacy statement