ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   copy data from sheet1 based on criteria in sheet2 to sheet3 (https://www.excelbanter.com/excel-programming/299219-copy-data-sheet1-based-criteria-sheet2-sheet3.html)

FRED May 24th 04 02:01 AM

copy data from sheet1 based on criteria in sheet2 to sheet3
 
I've tried seaching for a similar solution but have not found the answer

In sheet1, I have a list of buyer codes..i.e. 038, 247, 246 etc
The buyer list starts in a

On a sheet2 I have a list of open Purchase Orders with the buyer code in column

What I would like to do, for each buyer, copy matching POs to sheet3 (assume entire row), run a prefined macro, and then repeat the process for each buyer listed in sheet1.

Sheet3 could be cleared after the existing macro is ran

Thank you for your Help

Fred

No Name May 24th 04 02:57 AM

copy data from sheet1 based on criteria in sheet2 to sheet3
 
I don't know exactly what you are trying to accomplish but
I suspect it's not that hard. Can you elaborate a little?

John
-----Original Message-----
I've tried seaching for a similar solution but have not

found the answer:

In sheet1, I have a list of buyer codes..i.e. 038, 247,

246 etc
The buyer list starts in a2

On a sheet2 I have a list of open Purchase Orders with

the buyer code in column A

What I would like to do, for each buyer, copy matching

POs to sheet3 (assume entire row), run a prefined macro,
and then repeat the process for each buyer listed in
sheet1.

Sheet3 could be cleared after the existing macro is ran.

Thank you for your Help.

Fred
.


No Name May 25th 04 02:38 AM

copy data from sheet1 based on criteria in sheet2 to sheet3
 


Wouldn't using autofilter solve your problem? Overkill
would be using a listbox to select a given buyer # and
then have a macro copy their order onto a page 3 - but
this does not sound necessary.

John
-----Original Message-----
Sheet1 contains the results of an odbc query that looks

at an informix d/b and lists all of our buyers.

Sheet2 contains the results of an odbc query that looks

at an informix d/b and lists all of our "past due purchase
orders"

What I would like to do, is email a sheet to each buyer

of their Purchase Orders. I have a macro that emails the
current sheet. The problem is that I don't know how to
get each buyer's list of purchase orders on a separate
sheet.

I'm assuming that I must first list all buyers, search

for their Purchase Orders, copy that list to a new sheet,
then email the results. The list of Buyers and Purchase
orders would change each time I run the macro.

Hopefully, I've clarified myself.

Thanks.

Fred
.


FRED May 25th 04 01:46 PM

copy data from sheet1 based on criteria in sheet2 to sheet3
 
I totaly blew this one... I made this much more complicated than i needed to. I sorted sheet1 by the buyer code. then copied the sorted the range...emailed the sheet...went back to the original sheet...repeated the process.


All times are GMT +1. The time now is 09:28 PM.

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