vLOOKUP help

jwdemo

Board Regular
Joined
Dec 12, 2013
Messages
188
Office Version
  1. 2013
I am wanting to compare 2 sheets and return only the lines that contain matching UPC values to sheet 3.

Sheet 1 is a long list of products, most of which we do not carry in our store. The sheet contains corrections to some products that have recently been made. These corrections are marked in column A with the reason and are highlighted in green. All items that did NOT change have no data in column A.
Sheet 2 is a list of only products we carry.
Sheet 3 I would like to be a list of items that show up on both sheets and that had a change associated with them.

I would like to take the first UPC in Sheet 2 column C (C2) and look in the entire Sheet 1 column H for a match. If there is a match with an item that contains a change, I'd like the entire line copied into sheet 3.

I can use the excel filter tool to show only those with changes but they don't always start on line 1. Would the vLOOKUP be able to only use the visible items on sheet 1?
 
Would it be possible for me to email the file to you to look at?
We prefer to keep all possible communication within the public forum area. Some relevant references are points 18 & 19 of the Posting Guidelines and #7 of the Forum Rules

What problems are you having with Excel jeanie? It does work with Excel 2013 (unless it is the 64-bit Excel version).
The installation/activation is outlined by following the link in my signature then on the left "How To" then again on the left "Activating E 2007". Those instructions are written for 2007 but the steps are very similar for 2013.
 
Last edited:
Upvote 0

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Thanks for staying with me on this!

This is a sample of a line I want copied. All of the items for this particular brand are "changed" but none of them copied correctly.
[B]Sheet2[/B]

[TABLE]
<colgroup><col style="font-weight:bold; width:30px; "><col style="width:129px;"><col style="width:57px;"><col style="width:57px;"><col style="width:57px;"><col style="width:57px;"><col style="width:32px;"><col style="width:76px;"><col style="width:96px;"><col style="width:70px;"><col style="width:95px;"><col style="width:70px;"><col style="width:239px;"><col style="width:14px;"><col style="width:69px;"><col style="width:26px;"><col style="width:46px;"><col style="width:33px;"><col style="width:33px;"><col style="width:33px;"><col style="width:33px;"><col style="width:46px;"></colgroup><tbody>[TR="bgcolor: #cacaca"]
[TD] [/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD]O[/TD]
[TD]P[/TD]
[TD]Q[/TD]
[TD]R[/TD]
[TD]S[/TD]
[TD]T[/TD]
[TD]U[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]31[/TD]
[TD="bgcolor: #969696, align: center"]Correction[/TD]
[TD="align: center"]01/14/15[/TD]
[TD="align: center"]02/03/15[/TD]
[TD] [/TD]
[TD] [/TD]
[TD="align: center"]B-3[/TD]
[TD="align: center"]Grocery[/TD]
[TD="align: center"]084114-009944[/TD]
[TD="align: center"]36073[/TD]
[TD="align: left"]KETTLE[/TD]
[TD="align: center"]15/5 OZ[/TD]
[TD="align: left"]KETTLE NY CHEDDAR CHIPS[/TD]
[TD] [/TD]
[TD="bgcolor: #969696, align: center"]2/$4[/TD]
[TD] [/TD]
[TD="align: center"]24.23[/TD]
[TD="align: center"]20%[/TD]
[TD] [/TD]
[TD] [/TD]
[TD="align: center"]20%[/TD]
[TD="align: center"]19.94[/TD]
[/TR]
</tbody>[/TABLE]


[COLOR=#000000][FONT=Arial][B]Excel tables to the web >> [/B][/FONT][/COLOR][URL="http://www.excel-jeanie-html.de/index.php?f=1"] Excel Jeanie HTML 4 [/URL]
Here is how it copied over:
[B]Sheet3[/B]

[TABLE]
<colgroup><col style="font-weight:bold; width:30px; "><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"></colgroup><tbody>[TR="bgcolor: #cacaca"]
[TD] [/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD]O[/TD]
[TD]P[/TD]
[TD]Q[/TD]
[TD]R[/TD]
[TD]S[/TD]
[TD]T[/TD]
[TD]U[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]24[/TD]
[TD="bgcolor: #969696, align: center"]Correction[/TD]
[TD="align: center"]01/14/15[/TD]
[TD="align: center"]02/03/15[/TD]
[TD] [/TD]
[TD] [/TD]
[TD="align: center"]B-3[/TD]
[TD="align: center"]Grocery[/TD]
[TD="align: center"]084114-009944[/TD]
[TD="align: center"]36073[/TD]
[TD="align: left"]KETTLE[/TD]
[TD="align: center"]15/5 OZ[/TD]
[TD="align: left"]KETTLE NY CHEDDAR CHIPS[/TD]
[TD] [/TD]
[TD] [/TD]
[TD] [/TD]
[TD="align: center"]24.23[/TD]
[TD="align: center"]20%[/TD]
[TD="align: center"]20%[/TD]
[TD="align: center"]20%[/TD]
[TD] [/TD]
[TD="align: center"]19.94[/TD]
[/TR]
</tbody>[/TABLE]


[COLOR=#000000][FONT=Arial][B]Excel tables to the web >> [/B][/FONT][/COLOR][URL="http://www.excel-jeanie-html.de/index.php?f=1"] Excel Jeanie HTML 4 [/URL]

The shaded area shows up green on my screen. Column N did not copy over and the last several columns seem to be out of order.
 
Upvote 0
Good to see Excel jeanie emerging. :)

1. When using it ..

a) Don't enclose in IMG tags
b) It helps clearly identify rows & columns if you tick the 'Gridlines' box towards the bottom left of the interface.


2. Could you run this macro in your workbook & report the 4 results in order?
Rich (BB code):
Sub Check()
  Dim lcR1 As Long, lc As Long, HdrCountR1 As Long, HdrCount As Long
  
  With Sheets("Sheet2")
    lcR1 = .Cells(1, .Columns.Count).End(xlToLeft).Column
    lc = .Cells.Find(What:="*", After:=Cells(1, 1), LookIn:=xlValues, SearchOrder:=xlByColumns, _
      SearchDirection:=xlPrevious, SearchFormat:=False).Column
    HdrCountR1 = WorksheetFunction.CountA(Range("A1").Resize(, lcR1))
    HdrCount = WorksheetFunction.CountA(Range("A1").Resize(, lc))
    MsgBox lcR1 & vbLf & lc & vbLf & HdrCountR1 & vbLf & HdrCount
  End With
End Sub


3. Can you confirm that the green shading is standard cell formatting, not Conditional Formatting?
 
Last edited:
Upvote 0
Sorry to get back to you so long after your reply.

Nothing showed up on the Sheet 3 and a prompt came up that says:
26
26
0
0
 
Upvote 0

Forum statistics

Threads
1,215,603
Messages
6,125,771
Members
449,259
Latest member
rehanahmadawan

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