Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel.. find value in a 2D array

Status
Not open for further replies.

ceecld

Technical User
Jul 17, 2003
68
US
Hi im looking to find the cell ref of a particular number in an array, e.g.
A B C
--------
1| x y b
2| l m j
3| h i e

so in this simple example i might want ot know where "m" is located... B2

Im having trouble coming up with a formula to find this cell reference. Note that my arrays are 100x700.

Cheers
 
So you have 70000 unique numbers then?

Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 
70,000 yep... its a sparse matrix.. lots of zeros but all other values are unique
 
Row where item is: =SUMPRODUCT((A1:C3="m")*(ROW(A1:C3)))
Col where item is: =SUMPRODUCT((A1:C3="m")*(COLUMN(A1:C3)))

Does that help?

Cheers, Glenn.

Did you hear about the literalist show-jumper? He broke his nose jumping against the clock.
 
Or, combine the two to return an address..

Code:
=ADDRESS(SUMPRODUCT((A1:C3="m")*(ROW(A1:C3))),SUMPRODUCT((A1:C3="m")*(COLUMN(A1:C3))))


Regards,
Zack Barresse

Simplicity is the ultimate sophistication. What is a MS MVP? PODA
- Leonardo da Vinci
 
Hi ceecld:

If you have more than 1 entry of interest, then you may want to use ...

index.php


Yogi Anand, D.Eng, P.E.
Energy Efficient Building Network LLC
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top