Return Cell ID then use it in a formula

msdawg

New Member
Joined
Jul 24, 2006
Messages
8
I am trying to simplify a large worksheet by using a formula which looks up a text value in a column, returns its location (ex. A7), and then plugs "A7" into a formula. Since the list is dynamic and the position changes, it has to be able to update and can't be staticly locked. I have everything up to the point where I am trying to plug in a text "A7" located in another cell into my formula.

Any help would be appreciated.
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
hi - welcome to the board!

your description isn't quite clear enough - care to describe your data & exactly what you are trying to achieve - a worked example would help.
 
Upvote 0
There are a number of ways you might accomplish this depending on the formula in which you wish to plug the reference, can you post that?

Possibly one of

=INDIRECT("A"&MATCH("x",A:A,0))

or

=INDEX(A:A,MATCH("x",A:A,0))
 
Upvote 0
Thanks for the welcome.

To clarify what I'm looking for:

I am importing a large amount of data from a csv file and I am hoping to sort it automatically.

One row in column A is a header, then a series of data sets, then another header followed by it's data set, etc.

ex.

Apples
3
5
7
Oranges
4
6
8

I am hoping to use OFFSET to shift the data into a more usable format. However, I cannot just specify a start cell for the OFFSET because it will not always be the same starting point. I would rather look up the cell the header is located in, such as A3, and tell OFFSET to start from A3. It could easily be a different cell the next time.

I tried to use INDIRECT earlier, but I can't reference its resulting text as part of my formula.
 
Upvote 0
given the actual data you're working with, what distinguishes between the headers & the data? how much data have you got here (number of records / number of columns you need to generate)?
 
Upvote 0
About six groups.

a header
then 11 columns and then about 2400 rows
next header
11x2400
etc
etc

Not really desirable to go through and hunt for the headers each time.
 
Upvote 0
still no clear idea about your data - first of all we had one column ("One row in column A is a header, then a series of data sets..."), now we;ve got 11?

please describe it with an example.
 
Upvote 0
Looking at the base sample I think that What you are looking for is a way to distinguish numbers from text to locate the data. VBA can achieve this magnificently and very fast. If you can dump a CSV on the forum that would be great and then maybe I could help you achieve it.
 
Upvote 0
Do you realise this thread is 18 years old?
 
Upvote 0
Well, that's great. Resurrecting it from the dead like JESUS CHRIST! lol. Often these old posts are seen by others who may not have considered the alternatives...
 
Upvote 0

Forum statistics

Threads
1,221,580
Messages
6,160,625
Members
451,659
Latest member
honggamthienha

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top