Name manager - adding data manually as reference

Metty

New Member
Joined
Nov 6, 2019
Messages
12
Hello,

Normally we create named ranges by referring to excel lists - we select the data range that is located in certain cells in worksheets.

I tried to create named ranges by manually adding data to "refer to" part. But it didn't work - all the data that I added appeared in one cell, so not as a list.

I would like to know if there a way for adding data manually to "refer to" part and then use this list as named range whenever we need.

We can do it when we create custom lists, but these lists have no name. That's why I need named range for using it in different formulas.

Thank you in advance.
 

RoryA

MrExcel MVP, Moderator
Joined
May 2, 2008
Messages
34,146
Office Version
365, 2019, 2016, 2010
Platform
Windows, MacOS
It will depend on how you want to use the names, but you can create arrays by enclosing the data in {}, so for example, you could use:

={1,2,3,4,5}

as the refers to, or for text:

={"Item1","Item2","Item3"}

Note that the quotes go round each item, not around the whole thing.
 

jasonb75

Well-known Member
Joined
Dec 30, 2008
Messages
6,883
Office Version
2019
Platform
Windows
It might work if you set the the 'refers to ' range as an array constant, I haven't tried this so no guarantee. It looks like you're trying to make something simple more complicated than it needs to be.

={"Item1","Item2","item3"}

Then refer to it with an index formula,

=INDEX(list_name,ROWS(A$1:A1))
 

Metty

New Member
Joined
Nov 6, 2019
Messages
12
I tried this version, but it didn't work. Whenever I use the name, it's only the first item of the list that appears and when I drag it, it is repeated.


It will depend on how you want to use the names, but you can create arrays by enclosing the data in {}, so for example, you could use:

={1,2,3,4,5}

as the refers to, or for text:

={"Item1","Item2","Item3"}

Note that the quotes go round each item, not around the whole thing.
 

Metty

New Member
Joined
Nov 6, 2019
Messages
12
The problem with INDEX is that, it refers to existing list. I don't want to have lists in my worksheet, I want to have it only inside the name.

It might work if you set the the 'refers to ' range as an array constant, I haven't tried this so no guarantee. It looks like you're trying to make something simple more complicated than it needs to be.

={"Item1","Item2","item3"}

Then refer to it with an index formula,

=INDEX(list_name,ROWS(A$1:A1))
 

RoryA

MrExcel MVP, Moderator
Joined
May 2, 2008
Messages
34,146
Office Version
365, 2019, 2016, 2010
Platform
Windows, MacOS
Yes, you'll need to wrap it in INDEX as mentioned (that does not require you to use ranges, it works with arrays too).
 

Fluff

MrExcel MVP, Moderator
Joined
Jun 12, 2014
Messages
30,132
Office Version
365
Platform
Windows
Have you actually tried what Jason suggested? The list is in the name, not in a sheet.
 

RoryA

MrExcel MVP, Moderator
Joined
May 2, 2008
Messages
34,146
Office Version
365, 2019, 2016, 2010
Platform
Windows, MacOS
You must have done something different to what he suggested then.
 

Metty

New Member
Joined
Nov 6, 2019
Messages
12
Yes, I have just found the difference between my and his version, and it's ok now.

But as he said, it is now more complicated than it needs to be :)

I needed this function for simplifying my work with the fixed data that I use frequently without having lists in my sheets.

Thank you

You must have done something different to what he suggested then.
 

Forum statistics

Threads
1,077,662
Messages
5,335,561
Members
399,024
Latest member
rokcel389

Some videos you may like

This Week's Hot Topics

Top