View Full Version : Macro for copying based on criteria

10-10-2006, 05:39 AM
Hi All,

I have an excel file with two worksheets, one which is the input sheet and other is the main sheet(attached for your perusal).

In the main sheet, one would select (or enter manually) category as AAA or BBB or CCC or DDD.... etc.

Based on the selection criteria as AAA or BBB, i want to copy the relevant details from input sheet to the main sheet under Details. Please note that i do not want the entire column but just the table range for the respective criteria (without header). Since there are data above and below details, i want to have the table to be pasted with 2 blank lines before and after the Details.

Can someone please help with the visual basic code (for Macro) to acheive the same.

Any help would be highly appreciated.

Best Regards