Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() I am trying to incoporate a progress indicator in my spreadsheet and ca not get it work. I would appreciate any help to get this working. I hav the following code in module 1: Sub test() Dim fDetail As String Dim fAnswer As Integer Dim i As Integer Dim rCount As Integer Range("B2").Select Range(Selection, Selection.End(xlDown)).Select rCount = Selection.Rows.Count i = 0 t = 2 UserForm1.Show vbModeless For x = 1 To rCount fDetail = "=IF(I" & t & "="""",0,(O" & t & "/(SUM(IF(Block=C" & t ",IF(ElementRef=F" & t ",IF(Condition<"""",roomsize,0),0),0))))*MATC H(I" & t ",{""a"",""b"",""c"",""d""}))" Sheets("sheet1").Range("p2").Offset(i, 0).Select Selection.FormulaArray = fDetail Selection.Copy Selection.PasteSpecial Paste:=xlValues UserForm1.pcProgress i / rCount i = i + 1 t = t + 1 Next x Unload UserForm1 End Sub and in Userform1's module I have this code: Public Sub pcProgress(iPerCent As Integer) lbIndicate.Width = iPerCent * lbFixed.Width DoEvents End Su -- dcronj ----------------------------------------------------------------------- dcronje's Profile: http://www.excelforum.com/member.php...nfo&userid=528 View this thread: http://www.excelforum.com/showthread.php?threadid=26511 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Progress bar | Excel Discussion (Misc queries) | |||
Progress bar in VBE | Excel Programming | |||
Progress Bar | Excel Programming | |||
Progress Bar Help | Excel Programming | |||
Progress Bar Help | Excel Programming |