Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Excel Progress Bar problem


Hi All friends!

How can i display progress bar when some macro of Excel file is running.

How can i indicate user that which record is being processed out of
total.

Is there possible that i can use same userform(progressbarForm) to
display progress bar for different different macros?
Thanx

Ravi Patel


*** Sent via Developersdex http://www.developersdex.com ***
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,290
Default Excel Progress Bar problem

Ravi,
You should consider whether a dynamic message in the StatusBar would suffice.
It is easier to accomplish and requires less overhead...
'--
For i = 1 To lngTotal
Application.StatusBar = "Working " & Format$(i / lngTotal, "00%")
'some code
Next
'Don't forget this...
Application.StatusBar = False
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware
(Excel Add-ins / Excel Programming)



"go4ravi" <meet
wrote in message Hi All friends!
How can i display progress bar when some macro of Excel file is running.
How can i indicate user that which record is being processed out of
total.

Is there possible that i can use same userform(progressbarForm) to
display progress bar for different different macros?
Thanx

Ravi Patel


*** Sent via Developersdex http://www.developersdex.com ***
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,452
Default Excel Progress Bar problem

Or you could use this function, which will put a simple
progressbar in the statusbar.

Function MakeProgressString(lCounter As Long, _
lMax As Long, _
lInterval As Long, _
Optional lWidth As Long = 100, _
Optional strText As String) As String

Dim lStripes As Long

If lWidth = 0 Then
lWidth = 100
End If

If lCounter Mod lInterval = 0 Or lCounter = lMax Then
lStripes = Round((lCounter / lMax) * lWidth, 0)
MakeProgressString = strText & _
String(lStripes, "|") & _
String(lWidth - lStripes, ".") & "|"
End If

End Function


RBS


"Jim Cone" wrote in message
...
Ravi,
You should consider whether a dynamic message in the StatusBar would
suffice.
It is easier to accomplish and requires less overhead...
'--
For i = 1 To lngTotal
Application.StatusBar = "Working " & Format$(i / lngTotal, "00%")
'some code
Next
'Don't forget this...
Application.StatusBar = False
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware
(Excel Add-ins / Excel Programming)



"go4ravi" <meet
wrote in message Hi All friends!
How can i display progress bar when some macro of Excel file is running.
How can i indicate user that which record is being processed out of
total.

Is there possible that i can use same userform(progressbarForm) to
display progress bar for different different macros?
Thanx

Ravi Patel


*** Sent via Developersdex http://www.developersdex.com ***


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel Progress Bar Steven Taylor[_4_] Excel Programming 2 June 11th 07 06:46 AM
NEED Help - How to capture the Event's progress in Progress Bar Sriram Excel Programming 6 August 22nd 06 12:04 PM
ActiveX Progress bar initialization in Excel 2003 problem Siroc5 Excel Programming 3 July 8th 05 05:08 AM
Programming the Progress Bar problem Jeff Excel Programming 7 February 2nd 05 12:52 AM
progress bar problem still [email protected] Excel Programming 13 January 23rd 05 11:50 PM


All times are GMT +1. The time now is 06:10 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"