• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Excel Search Column and return multiple rows

Nu2Java

Member
Hello, I have been trying to search for a VBA method or Formula for this issue I am having but with no luck. In the attached file, I want to search for a string in Column C which will have many duplicates. After each instance found, return the rows where duplicates are found in ROW A and/or B. I have put an example in the attached workbook. I have no problem searching for a string and returning that row, but have no idea how to return other rows based on a cell from the search. I hope it makes sense in the workbook.
 

Attachments

  • Job Sheet - Copy.xlsx
    13.2 KB · Views: 5
Nu2Java
... so You meant something like this after press [ Do It ] ?

vletm, this looks very good. I am trying to understand all the code, so what I would like is to have a search for a single job, or just put a job number in a cell and return the data from those rows so I can visually see how many other jobs share the parts from the one I searched. I will play around with this code until I hear back from you. Thanks a lot
 
Nu2Java
You wrote #1: I want to search for a string in Column C which will have many duplicates. After each instance found, return the rows where duplicates are found in ROW A and/or B.
As many times:
1) think, what do You would like to get
2) think again
3) write down what You really would like to get
4) read You text
5) think again
6) if everything is as You would like to get then press [Post Reply]
Now You can get all duplicates with rows in one time!
 
@vletm I think I worded part of it incorrectly. I want to enter a JOB NUMBER in Cell E1 to find all matches in Column C, then run your code to get the data from all rows found in Column A,B,C. Your code works great, I just don't want the row number, just the data from those rows. Data all in one column would be great.
 
Nu2Java
Did You think twice?
'Data all in one column would be great.' --- really?
Did You try to figure what do it look like?
Try to do it manually and think twice again what do You really would like to get.
 
Nu2Java
Did You think twice?
'Data all in one column would be great.' --- really?
Did You try to figure what do it look like?
Try to do it manually and think twice again what do You really would like to get.
You are correct... 3 columns of returned data. This is what it would look like.
 

Attachments

  • Job Search - Copy.JPG
    Job Search - Copy.JPG
    90.3 KB · Views: 11
Thanks @NARAYANK991 I can work with this. I'm trying to now put in actual job data which goes to row 6000 and have the color update as well. How do I update your dropdown box of job numbers? I can't seem to do it without getting an error that the data entered is restricted. As I am playing around with this, I really need the other Job numbers to show as well. What I am ultimately trying to accomplish is... I have JOB A-F and when I get a new JOB-G, I need to find out from the entire parts list which existing jobs have the most commonality of parts to JOB-G. I hope I am making sense.
 
Last edited:
Nu2Java
Your 'new version of layout' is ...
No way,
Test this version.
You can add as many rows as You need
as well as many 'JOB NUMBER' as You need
After that select from cell[E1] You 'JOB NUMBER' ...
There is still that You original version possible to use.
 

Attachments

  • Job Sheet - Copy.xlsb
    24.1 KB · Views: 6
Thanks @NARAYANK991 I can work with this. I'm trying to now put in actual job data which goes to row 6000 and have the color update as well. How do I update your dropdown box of job numbers? I can't seem to do it without getting an error that the data entered is restricted. As I am playing around with this, I really need the other Job numbers to show as well. What I am ultimately trying to accomplish is... I have JOB A-F and when I get a new JOB-G, I need to find out from the entire parts list which existing jobs have the most commonality of parts to JOB-G. I hope I am making sense.
Hi ,

See this for an explanation.

http://www.contextures.com/xlDataVal01.html

Narayan
 
Nu2Java
Your 'new version of layout' is ...
No way,
Test this version.
You can add as many rows as You need
as well as many 'JOB NUMBER' as You need
After that select from cell[E1] You 'JOB NUMBER' ...
There is still that You original version possible to use.
@vletm thanks for the help. I think this might be the best possible solution for what I need until I work towards my long-term solution
 
Back
Top