HELP me PLZ

KOK

Board Regular
Joined
Aug 9, 2010
Messages
115
Hello All,
I require help for the following question :
I have data in Sheet1, Row 1,which contains unique data , and this data
scattered in Sheet2, which is also unique.
Now, on Sheet1 , on Row2, I want the address of cell where the cell can
be found in Sheet2.
For eg. On Sheet1 Cell A1 - contains value - 100, and it can be found on
Sheet2 at c55, now I want this cell reference on Sheet1, B1.

Thanks in Advance..!!:biggrin:
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
Hi...

Are there any duplicate numbers in the lookup column ?
 
Upvote 0
Anywhere on sheet 2, or is your data within a specific range?

Pre Excel2007 a sheet consisted of 256 columns x 65, 000 rows, so more than 16 million cells in which to look.
 
Upvote 0
Try:
Code:
Sub FindUniques ()
Application.ScreenUpdating = False
Dim i as Long
Dim FoundCell as Range
On Error Resume Next
With Sheets("Sheet1")
For i = 1 to .cells(1, Columns.Count).End(xlToLeft).Column
  FoundCell = Sheets("Sheet2").Cells.Find(what:=.cells(1,i), after:=Sheets("Sheet2").cells(1,1).Address
  If FoundCell Is Nothing Then
    .cells(2,i) = "Value not found"
  Else
    .cells(2,i) = FoundCell.Address
  End If
Next i
End Sub
 
Upvote 0
Data is unique in lookup and in sheet2 data is anywhere...

Hello JackDanIce

When I ran the code I found error for the line
FoundCell = Sheets("Sheet2").Cells.Find(what:=.cells(1,i), after:=Sheets("Sheet2").cells(1,1).Address

Thanks..

You guys are really HELPFULL>>!!
 
Upvote 0
My error, try:
Code:
Sub FindUniques ()
Application.ScreenUpdating = False
Dim i as Long
Dim FoundCell as Range
On Error Resume Next
With Sheets("Sheet1")
For i = 1 to .cells(1, Columns.Count).End(xlToLeft).Column
  FoundCell = Sheets("Sheet2").Cells.Find(what:=.cells(1,i), after:=Sheets("Sheet2").cells(1,1))  
  If FoundCell Is Nothing Then
    .cells(2,i) = "Value not found"
  Else
    .cells(2,i) = FoundCell.Address
  End If
Next i
End With
Application.ScreenUpdating = True
End Sub
 
Last edited:
Upvote 0
Ok I got it now , I made correction with : End With

thank you very much all of you ....:)
 
Upvote 0

Forum statistics

Threads
1,224,583
Messages
6,179,671
Members
452,937
Latest member
Bhg1984

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