Help Please. How make passive macro?

elkinm

Platinum Member
Jun 9, 2001
2,146
0
71
I want to create a macro that will monitor a cells with links and update those or other cells.

The problem is that when the macro code is running, then excel does not update until the code finishes, so if there is a loop based on updates of external cells, then the loop will never end.

Is there any way to run the macro with low priority or pause it periodical so excel can update before the next loop of the code?

Thanks
elkinm
 

KB

Diamond Member
Nov 8, 1999
5,406
389
126
I don't think excel supports threading. Instead you should put some code checks in one of the many events.

For example in the changed worksheet event check which cell was changed:

Private Sub Worksheet_Change(ByVal Target As Range)
'check what cell is updated
End Sub