ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   conditional programming (https://www.excelbanter.com/excel-programming/372045-conditional-programming.html)

fascal

conditional programming
 
Hi,

I have a workbook where I want to copy data from one sheet to another sheet
based on a columns criteria.

If Worksheet_1, column A has the value 13-2006, I want all the rows that
contain this value to populate the empty Worksheet_2.

How do I write the if statement to make this happen?

Thanks.

Dave Peterson

conditional programming
 
Apply data|filter|autofilter to that column A.
Show the 13-2006 rows
copy those visible rows to the new sheet.

If you need a macro, you could record one when you do it manually.

fascal wrote:

Hi,

I have a workbook where I want to copy data from one sheet to another sheet
based on a columns criteria.

If Worksheet_1, column A has the value 13-2006, I want all the rows that
contain this value to populate the empty Worksheet_2.

How do I write the if statement to make this happen?

Thanks.


--

Dave Peterson


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

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