Search // Append // Review & Notify.

Habu

New Member
Joined
Nov 10, 2004
Messages
13
I have a listing of data (see below). This data is much larger than what I have posted but I posted this as an example.

Column A Column B
Row
1 040 54481
2 064 54703
3 070 54911
4 072 55025
5 550 55033
6 55044
7 55057
8 55068

What I need is a special search and notification that will do the following. I need it to only look at the first three (3) digits for the list of numbers in Column B, then compair them against the three (3) numbers in Column A.

So that if/when there is a match with Column A I will get the following results.

Column A Column B Column C
Row
1 040 54481 No
2 064 54703 No
3 070 54911 No
4 072 55025 No
5 550 55033 Yes
6 55044 Yes
7 55057 Yes
8 55068 Yes
9 04088 Yes
10 06499 Yes
11 07299 Yes

Thankx,
Habu (y)
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
Give this a go:
Code:
Sub tt()
Dim c As Range, rng As Range

Set rng = Range("A2:A" & Range("A65536").End(xlUp).Row)
For Each c In rng
If Format(c.Value, "###") = Format(Left(c.Offset(0, 1).Value, Len(c.Value)), "###") _
            Or c.Offset(0, 1).Value = "" Then
    c.Offset(0, 2).Value = "YES"
Else
    c.Offset(0, 2).Value = "No"
End If
Next c

End Sub
HTH.
 
Upvote 0

Forum statistics

Threads
1,214,918
Messages
6,122,241
Members
449,075
Latest member
staticfluids

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