Defined names in Macros

H

herb19355

This is frustrating me to no end... I feel like it must be something
simple and I am missing it.

I have names defined in my worksheet which are defined as calculations.


I want to use those name (calculations) in my Macro's to display a
message box.

For example Changes is defined as =counta($A:$A) and I want to display
a message box which say "The number of Changes is: (number of changes)"

Help please!
 
B

Bob Phillips

MsgBox "Number of changes is: " &
ActiveSheet.Evaluate(ActiveWorkbook.Names("changes").RefersTo)


--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top