agarwaldvk
04-10-2008, 05:36 PM
Hi Everybody
Is there a way to capture the text displayed on the Excel status bar using VBA? Further, is there a way to interrupt and then resume the recalculation process intermittently?
The exact requirement is as follows :-
If Excel is doing a recalculation - fairly intense recalculation which takes around 5 minutes to complete (I know this is very substantial but that is how it is) - initiated by invoking the appropriate command in VBA, is it possible to display in a message box intermittently to dsplay the extent to which the calcuation has been completed as is 10%, 20% etc. by capturing the text displayed on the status bar.
The reason for needing to do so is that the normal front end is not visible whilst this macro is running since a custom user form is displayed in full screen mode (the status bar is hence not visible to the user).
To realise this, I think (more than likely incorrectly) thatI will need to take the control away from the recalculation process intermittently to read the status bar text and display it in another user form - should I choose to display the progress this way and then resume the recalculation process.
Is that right? And if it is, how do I stop the recalculation process part way and how do I read the status bar text? I know how to display custom text on the status bar not how to read what is displayed.
For the first part, would DoEvents do it or am I on a totally wrong track?
For the second part, I have no idea and need your assistance please!
Best regards
Deepak Agarwal
Is there a way to capture the text displayed on the Excel status bar using VBA? Further, is there a way to interrupt and then resume the recalculation process intermittently?
The exact requirement is as follows :-
If Excel is doing a recalculation - fairly intense recalculation which takes around 5 minutes to complete (I know this is very substantial but that is how it is) - initiated by invoking the appropriate command in VBA, is it possible to display in a message box intermittently to dsplay the extent to which the calcuation has been completed as is 10%, 20% etc. by capturing the text displayed on the status bar.
The reason for needing to do so is that the normal front end is not visible whilst this macro is running since a custom user form is displayed in full screen mode (the status bar is hence not visible to the user).
To realise this, I think (more than likely incorrectly) thatI will need to take the control away from the recalculation process intermittently to read the status bar text and display it in another user form - should I choose to display the progress this way and then resume the recalculation process.
Is that right? And if it is, how do I stop the recalculation process part way and how do I read the status bar text? I know how to display custom text on the status bar not how to read what is displayed.
For the first part, would DoEvents do it or am I on a totally wrong track?
For the second part, I have no idea and need your assistance please!
Best regards
Deepak Agarwal