Re: Execution branches unexpectedly to UDF when stepping through
Many thanks for your reply. As you suggested, upon opening the text file, the volatile udf is being recalculated. As a kludgy fix I tried turning on manual calc prior to opening the text file and turning auto calc back on after opening, but as soon as auto calc is turned back on the code immediately branches to the volatile udf.
I played with the Application.Volatile method to the extent that I commented it out with the result that there was no prob with branching to the udf. However I need that (and other) udf's to be volatile.
So no remedy at this stage.... anyone?
AAMOI: The explanation for the #VALUE! being returned in the wksht containing the volatile udf was because I was manually aborting the code while the volatile udf was in the process of executing.