View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.programming
slarbie slarbie is offline
external usenet poster
 
Posts: 53
Default Public Range Constant - how do I?

Thanks again, I was just setting about to figure out why it had stopped
working. Hmmm. I'll have to figure out how I want to deal with that... Is
it preventable if I have sufficiently robust error handling in the
procedures, so break mode doesn't happen?

"Howard31" wrote:

Keep in mind that if in any time after setting the range object, the VB goes
into Break mode, the range object will become disassociated from "MyRange",
that means it will become an empty range variable = Nothing and you'll have
to reset it to "MyRange"
--
A. Ch. Eirinberg


"slarbie" wrote:

In all the modules/procedures of my project, I'd like to be able to refer to
a specific named range as a constant. I imagined this:

Public const MyRange as Range = Range("MyRange")

at the top of a module, but it doesn't work. Can someone help with the
right way to do what I'm trying to get at here? Thanks!