It is pretty much widely accepted that this is not \'best practise\'.
dim rng as range
with thisworkbook \'<~~ possibly set an external workbook
w
The answer seems to be: only if the code is located in a Worksheet object. I strongly suspect that this is because the Worksheet objects are the only ones that are both extensible and have a Range
function. When Range
is called from a Worksheet, that object's Range
function has scope. When the code is located in ThisWorkbook or a user module or class, the Range
function with the closest available scope is the global Range
object (assuming of course that there isn't a user defined Range
function). That one is tied to the Application
, which has to resolve it based on the passed parameters and forward the call to the correct Worksheet.