ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Named Ranges - what characters are (or are not) allowed in the nam (https://www.excelbanter.com/excel-discussion-misc-queries/103158-re-named-ranges-what-characters-not-allowed-nam.html)

Bernie Deitrick

Named Ranges - what characters are (or are not) allowed in the nam
 
Barb,

Names can contain letters, numbers, and underscores, and the first character cannot be a number.
Also, the name cannot be interpreted by Excel as a valid range address in either A1 or R1C1
notation: C, C1, AA45, CC1245, R12C13, etc are invalid. And it's a good idea to have at least 5
leading alpha characters, since Excel 2007 will have up to 4 alphas as column letters.

Visit

http://www.cpearson.com/excel/named.htm

for more.


HTH,
Bernie
MS Excel MVP


"Barb Reinhardt" wrote in message
...
I'm trying to create named ranges programmatically and need to know what
characters are and are not allowed in the names. So far, I assume that _ and
text are included. I know that a lot of special characters are not
(&,+,-,space, etc).

Can someone assist?

Thanks,
Barb




Niek Otten

Named Ranges - what characters are (or are not) allowed in the nam
 
<Also, the name cannot be interpreted by Excel as a valid range address in either A1 or R1C1

Good point! And if there's any chance of your workbook being used in other language versions of Excel (RK, LC, etc) avoid this
construction anyway.

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"Bernie Deitrick" <deitbe @ consumer dot org wrote in message ...
| Barb,
|
| Names can contain letters, numbers, and underscores, and the first character cannot be a number.
| Also, the name cannot be interpreted by Excel as a valid range address in either A1 or R1C1
| notation: C, C1, AA45, CC1245, R12C13, etc are invalid. And it's a good idea to have at least 5
| leading alpha characters, since Excel 2007 will have up to 4 alphas as column letters.
|
| Visit
|
| http://www.cpearson.com/excel/named.htm
|
| for more.
|
|
| HTH,
| Bernie
| MS Excel MVP
|
|
| "Barb Reinhardt" wrote in message
| ...
| I'm trying to create named ranges programmatically and need to know what
| characters are and are not allowed in the names. So far, I assume that _ and
| text are included. I know that a lot of special characters are not
| (&,+,-,space, etc).
|
| Can someone assist?
|
| Thanks,
| Barb
|
|




All times are GMT +1. The time now is 02:19 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com