Declaring the name of the variable from a cell value

obener

Board Regular
Joined
May 31, 2009
Messages
118
hi all,

i just wanted to know if there is a way of declaring a variable and setting the name of the variable from a cell value?

thanks
 

Some videos you may like

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.

JoeMo

MrExcel MVP
Joined
May 26, 2009
Messages
17,187
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
When you declare a variable you have to furnish a name for it. You can set the value of that variable equal to a cell's value. Why would you want to change the name of the variable?
 

mikerickson

MrExcel MVP
Joined
Jan 15, 2007
Messages
23,779
Short answer, No.
Longer answer, Names can be referenced by the contents of a cell, but that doesn't sound like what you are looking to do.
Are you looking to have a list of text values matched with a list of other values, if so, a VLookup array is probably the best way.

What are you trying to achieve?
 

obener

Board Regular
Joined
May 31, 2009
Messages
118
that's what i thought but i just wanted to confirm it. What i'm going to do is go through a list of exams and see which ones are completed as each exam has multiple parts in them but I may just use counter(x) where x can change for different ones.
 

Watch MrExcel Video

Forum statistics

Threads
1,108,501
Messages
5,523,293
Members
409,508
Latest member
Afc

This Week's Hot Topics

Top