ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   vlookup more then 1 match or how do I (https://www.excelbanter.com/excel-worksheet-functions/235384-vlookup-more-then-1-match-how-do-i.html)

magicaldean

vlookup more then 1 match or how do I
 

Hello and thanks for taking the time to look and try to help

I have a list of info on sheet "open orders" with columns A=SO#, B=ID#,
C=QTY, that uses a choose function to get this info from a different
sheet. there might be a SO# listed from 1-30 times with a different ID#
and QTY in the next columns

On sheet "items" I want to type a SO# (listed on the "open orders"
sheet) into cell "B1" and have a list of all ID# and there QTYs be
listed on sheet "items" in cells A4 and B4 and down.

please look at this file i have attached as a idea of what i am trying
to say

please let me know any questions you may have


+-------------------------------------------------------------------+
|Filename: help.xls |
|Download: http://www.thecodecage.com/forumz/attachment.php?attachmentid=171|
+-------------------------------------------------------------------+

--
magicaldean
------------------------------------------------------------------------
magicaldean's Profile: http://www.thecodecage.com/forumz/member.php?userid=453
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=111260


Roger Govier[_3_]

vlookup more then 1 match or how do I
 
Hi

Insert a new row on your Goal Sheet.
In cell B1 type SO No
In Cell B2 enter the Order Number you want.

In cells A4 and B4 type Item ID and Qty Rem
Note - these must be the same as the column headings on your Open Orders
Sheet.

Copy the following event code to the Goal Sheet

Private Sub Worksheet_Change(ByVal Target As Range)

If Target.Address < "$B$2" Then Exit Sub

Sheets("open orders").Range("A:C").AdvancedFilter Action:=xlFilterCopy,
_
CriteriaRange:=Range("B1:B2"), _
CopyToRange:=Range("A4:B4"), _
Unique:=False

End Sub

Copy the Code above
Right click Goal Sheet tab View Code
Paste code into white pane that appears
Alt+F11 to return to Excel

This is event code which will be triggered automatically as you enter a new
number in cell B2

--
Regards
Roger Govier

"magicaldean" wrote in message
...

Hello and thanks for taking the time to look and try to help

I have a list of info on sheet "open orders" with columns A=SO#, B=ID#,
C=QTY, that uses a choose function to get this info from a different
sheet. there might be a SO# listed from 1-30 times with a different ID#
and QTY in the next columns

On sheet "items" I want to type a SO# (listed on the "open orders"
sheet) into cell "B1" and have a list of all ID# and there QTYs be
listed on sheet "items" in cells A4 and B4 and down.

please look at this file i have attached as a idea of what i am trying
to say

please let me know any questions you may have


+-------------------------------------------------------------------+
|Filename: help.xls |
|Download:
http://www.thecodecage.com/forumz/attachment.php?attachmentid=171|
+-------------------------------------------------------------------+

--
magicaldean
------------------------------------------------------------------------
magicaldean's Profile:
http://www.thecodecage.com/forumz/member.php?userid=453
View this thread:
http://www.thecodecage.com/forumz/sh...d.php?t=111260



All times are GMT +1. The time now is 08:55 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com