View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Application.Volatile Question, HelP!!!

I think I'd do my best to remove the application.volatile line and pass the
parms that I need to the UDF.

But if that's not possible, maybe you could disable events, run your code and
enable events.

application.enableevents = false
'your code here
application.enableevents = true



k. moran wrote:

Okay here's my problem,

I have a VBA subroutine (Marco) that I want to run, BUT in my worksheets I
also have functions that I've written (in VBA) that are Application.Volatile.

So when I run the subroutine, Excel also has to re-calculate "all" the
functions in all cells that are in all the worksheets.

What happens is that everything grinds to a halt!

What can I do???

Much Thanks As Always! Kurt

Function TotalPCRs() As Integer

Application.Volatile


--

Dave Peterson