|
-
Apr 5th, 2001, 10:21 AM
#1
Thread Starter
Junior Member
Anyone know how to get a progress bar in a statusbar like in Internet Explorer?
VB6 Enterprise (COM, ADO, ActiveX)
SQL Server 7
HTML

-
Apr 5th, 2001, 10:27 AM
#2
Add a Statusbar and a Progress bar..
Code:
Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
'form load...
SetParent ProgressBar1.hwnd, StatusBar1.hwnd
With StatusBar1
Progressbar1.Move 30, 50, .Panels(1).width - 30, .height - 65
End With
VBBrowser v2.2.1
JPnyc rocks!! (Just ask him!)
If u have your answer please go to the thread tools and click "Mark Thread Resolved"
-
Apr 5th, 2001, 10:34 AM
#3
Thread Starter
Junior Member
Cool, thanks geoff
VB6 Enterprise (COM, ADO, ActiveX)
SQL Server 7
HTML

-
Apr 6th, 2001, 04:34 AM
#4
Thread Starter
Junior Member
Is there any way I can do this with 2 progressbars in the same statusbar? I tried this:
Code:
Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Private Sub Form_Load()
SetParent prgListProgress.hWnd, sbrStatus.hWnd
With sbrStatus
prgListProgress.Move 30, 50, .Panels(1).Width - 30, .Height - 65
End With
SetParent prgProgress.hWnd, sbrStatus.hWnd
With sbrStatus
prgProgress.Move 30, 50, .Panels(2).Width - 30, .Height - 65
End With
End Sub
But it only works for the first progressbar.
VB6 Enterprise (COM, ADO, ActiveX)
SQL Server 7
HTML

-
Apr 6th, 2001, 04:50 AM
#5
Thread Starter
Junior Member
Actually, I just noticed that it's putting both progressbars into panel 1, so is there anyway to tell it what panel it should be in?
VB6 Enterprise (COM, ADO, ActiveX)
SQL Server 7
HTML

-
Apr 6th, 2001, 04:54 AM
#6
Thread Starter
Junior Member
Nevermind, figured it out. Just had to use .Panels(2).Left.
VB6 Enterprise (COM, ADO, ActiveX)
SQL Server 7
HTML

-
Apr 6th, 2001, 07:05 AM
#7
Fanatic Member
Draco,
Would you mind posting the code you used to get 2 progressBars in the statusBar?
Thanks.
-
Apr 6th, 2001, 07:10 AM
#8
Thread Starter
Junior Member
No prob. 
First put 2 progressbars and a statusbar on the form (as previously mentioned), with 2 panels in the statusbar (just stating the obvious ).
Code:
Private Declare Function SetParent Lib "user32" (ByVal hWndChild As Long, ByVal hWndNewParent As Long) As Long
Private Sub Form_Load()
SetParent prgListProgress.hWnd, sbrStatus.hWnd
With sbrStatus
prgListProgress.Move .Panels(1).Left, 50, .Panels(1).Width - 30, .Height - 65
End With
SetParent prgProgress.hWnd, sbrStatus.hWnd
With sbrStatus
prgProgress.Move .Panels(2).Left, 50, .Panels(2).Width - 30, .Height - 65
End With
End Sub
VB6 Enterprise (COM, ADO, ActiveX)
SQL Server 7
HTML

-
Apr 6th, 2001, 07:14 AM
#9
Fanatic Member
Thanks !!
I was close, but not close enough to get it to work right.
-
Apr 20th, 2001, 02:06 PM
#10
Lively Member
How do you get this to work with an MDI Parent?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|