Why cannot name a function A1 or NA77?

  • Thread starter Thread starter vsoler
  • Start date Start date
V

vsoler

Why cannot name a function A1 or NA77?

Then a call to these functions is unable to find their definitions and
a #REF! is returned.

What's the problem?
 
Just as a side note, Excel 2007 has 16,384 columns, versus 256 in
earlier version, so what were in 2003 and earlier valid function names
and defined names are no long valid as names in 2007. E.g,. In 2003,
you could have a function like

Function NA77(D As Double) As Double
NA77 = D * 100
End Function

This would work because in 2003, NA77 is not a valid cell address and
is thus legal as a function name. Bring that workbook into Excel 2007
and NA77 is a valid cell address, so the function won't be called and
you'll get errors.

Similarly, in 2003, NA77 could be used as a defined name since it was
not a valid cell address. If you bring that into 2007, Excel will ask
to change the defined name to _NA77 but won't attempt to change any
VBA code. Thus, you could get errors or unexpected results.

The summary, then, is to use longer names for functions and defined
names so you won't have problems when moving to 2007 and beyond.

Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2009
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)
 
Excel 2007 didn't like my named ranges POP1, POP2, POP3 for this very reason.
What a PITA to change 'em all.
 
Back
Top