Oct 24 2023 08:09 AM
Hi,
I have a conditional format on a range.
Because the size of the range can change, I want also adapt dynamically the range on which the conditional format speaks .
Since you cannot use named ranges in conditional format, I use VBA:
'range.ModifyAppliesToRange newrange'
This works, but as soon the next line of code is launched, then excel crashes and closes after a few seconds. This next line is: debug.print "test", so this should not fail.
I tried with a pauze after changing the cond format range, but unsuccessful (I thought maybe excel needs some time to change the format).
I also tested this on different computers.
Any suggestions to resolve this?
kr
Wannes
Oct 25 2023 01:44 AM
Oct 25 2023 10:47 AM
Solution