Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel VBA - Filter and Copy rows based on input box

Status
Not open for further replies.

nigelapt

IS-IT--Management
Jun 6, 2001
12
GB
Hi Everyone
Be grateful for any advice on the following:

I have a worksheet detailing all the items invoiced to each customer which is downloaded from our accounts system daily. The sheet is sorted by invoice no/product. The invoice number can relate to many different rows within the sheet. As I need to be able to select more than 2 invoice numbers, the custom autofilter is no use.
Is there anyway I can prompt users to enter in a range of invoice numbers, and then filter and copy the results into a new worksheet?

Thanks!

Nigel
 
You may still use the autofilter stuff with 2 conditions ANDed (>=minNunmer AND <=maxNumber)

Hope This Help, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884
 
Hi Nigel!

I have accomplished something similar using the Advanced Filter (AdF). The AdF considers each criteria line to be a "set" of conditions, so if you have, say, 5 criteria rows, the AdF will return all data rows that match any of the 5 criteria rows.

See my last post in thread707-811281 for more details on how to implement it.

Let me know if that helps!

VBAjedi [swords]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top