Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Implement a progress bar when the macro run inside another workboo
Hi,
I have a macro that generate a Word document from Excel with a progress bar indicator. I have another Excel file (main file) that can create Word report one by one by opening an excel file #1, create the report #1, opening excel file #2, word report #2, etc. During this process, I would like to indicate the progress bar of the file #1. #2, ... inside the main excel file progress bar. Thank you! Alex File #1 33%, 34%, 35%, etc. File #2 0% File #3 0% I have a macro which is called "ExecuteReport" inside "Thisworkbook" class module which is executed from the main excel file like: Dim wb As Workbook Load UserForm1 'ProgressBar UserForm1.Show For Each wb in ... Set wb = Workbooks("File #i.xls") wb.Executereport 'Is there a way to update Userform1 ProgressBar during the production of the word document. (takes 2 minutes to do!) set Wb = Nohting Next wb -- Alex St-Pierre |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Implement a progress bar when the macro run inside another workboo
There are a couple of possible solutions here...
http://j-walk.com/ss/excel/files/developer.htm Check out Controlling LEDs and progress indicator. -- HTH... Jim Thomlinson "Alex St-Pierre" wrote: Hi, I have a macro that generate a Word document from Excel with a progress bar indicator. I have another Excel file (main file) that can create Word report one by one by opening an excel file #1, create the report #1, opening excel file #2, word report #2, etc. During this process, I would like to indicate the progress bar of the file #1. #2, ... inside the main excel file progress bar. Thank you! Alex File #1 33%, 34%, 35%, etc. File #2 0% File #3 0% I have a macro which is called "ExecuteReport" inside "Thisworkbook" class module which is executed from the main excel file like: Dim wb As Workbook Load UserForm1 'ProgressBar UserForm1.Show For Each wb in ... Set wb = Workbooks("File #i.xls") wb.Executereport 'Is there a way to update Userform1 ProgressBar during the production of the word document. (takes 2 minutes to do!) set Wb = Nohting Next wb -- Alex St-Pierre |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Implement a progress bar when the macro run inside another wor
Thank's
Finally I did it by a transfer of the userform from wb#1 to wb#2. In wb #1: With UserForm1 .FrameProgress.Caption = Format(PctDone, "0%") .LabelProgress.Width = PctDone * (.FrameProgress.Width - 10) End With DoEvents Dim wb As Workbook Dim docWord As Word.Document Set wb = Workbooks("abc.xls") wb.ExecuteReport docWord:=docWord, ExcelTable:=False, UserForm:=UserForm1 In wb #2, I have added the parameter: Public Sub ExecuteReport(docWord As Word.Document, ExcelTable As Boolean, userform As Object) userform.FrameProgress.Caption = "Alex" update the userform!! Thank's a lot! -- Alex St-Pierre "Jim Thomlinson" wrote: There are a couple of possible solutions here... http://j-walk.com/ss/excel/files/developer.htm Check out Controlling LEDs and progress indicator. -- HTH... Jim Thomlinson "Alex St-Pierre" wrote: Hi, I have a macro that generate a Word document from Excel with a progress bar indicator. I have another Excel file (main file) that can create Word report one by one by opening an excel file #1, create the report #1, opening excel file #2, word report #2, etc. During this process, I would like to indicate the progress bar of the file #1. #2, ... inside the main excel file progress bar. Thank you! Alex File #1 33%, 34%, 35%, etc. File #2 0% File #3 0% I have a macro which is called "ExecuteReport" inside "Thisworkbook" class module which is executed from the main excel file like: Dim wb As Workbook Load UserForm1 'ProgressBar UserForm1.Show For Each wb in ... Set wb = Workbooks("File #i.xls") wb.Executereport 'Is there a way to update Userform1 ProgressBar during the production of the word document. (takes 2 minutes to do!) set Wb = Nohting Next wb -- Alex St-Pierre |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to implement the progress bar to indicate the Macro start to finish | Excel Programming | |||
Need help with a macro that takes information from another workboo | Excel Programming | |||
Macro question - Need to copy data & formatting to another workboo | Excel Programming | |||
Can you code a macro so it runs multiple times in the same workboo | Excel Discussion (Misc queries) | |||
Implement object persistence inside Excel | Excel Discussion (Misc queries) |