![]() |
Want to move records
I would like to move records based on a flag.
I do NOT want to just copy the record. How do you do this? I would like to walk the records, and then if the flag is true, them move it to a diff worksheet. I imagine it would be something like: sub MoveRec reccount= RowCount for i =1 to reccount if active.cell(0,3) then Worksheets("Sheet1").Range("A:ZZ").Cut ActiveSheet.Paste Destination:=Worksheets("Sheet2").Range("A:ZZ") endif next i end sub Will this work? I don't want to try it until I get somebodys OK that this will do what I want it to do. Is there a better way to do this? Thanks Phil |
All times are GMT +1. The time now is 11:14 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com