Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I got this sample code from a website, i tried to use it for my needs but it
does not work. This code stops at the first event of finding something that matches.. id like excel to continue looking and gather all results and put them in 1 new sheet. how can i modify the code to do what i want i to? I am looking up column C in a master sheet into another workbook with 15 sheets, I will be looking up the same column in each sheet, for example, column c in master sheet will be looked into column c of each of the 15 sheets, it doesnt need to return anything additional other than whether it appears in any of the sheets, so if i was writing a vlookup it would end with '1,false'. And ideally the results will be displayed on a new sheet. Dim wSheet As Worksheet Dim vFound On Error Resume Next For Each wSheet In ActiveWorkbook.Worksheets With wSheet Set Tble_Array = .Range(Tble_Array.Address) vFound = WorksheetFunction.VLookup _ (Look_Value, Tble_Array, _ Col_num, Range_look) End With If Not IsEmpty(vFound) Then Exit For Next wSheet Set Tble_Array = Nothing VLOOKAllSheets = vFound End Function Thanks a lot for all your help. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
how do i sum the same cell in numerous sheets behind a main | Excel Worksheet Functions | |||
return same cell value from numerous sheets | Excel Worksheet Functions | |||
how to lookup in numerous different sheets | Excel Discussion (Misc queries) | |||
Comparing numerous sheets | Excel Discussion (Misc queries) | |||
propogating cells with data from numerous sheets | Excel Programming |