Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cut and Paste range
Hi All
I have data in column A that says JN or HR or CH I want Excel to identify all data in column A and paste the data into a different sheet i.e All data that starts with JN in column A will be pasted into a JN sheet and all data that starts HR will go ito a sheet called HR Any Ideas?? -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...mming/200512/1 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cut and Paste range
Hi
You could sort the data, then filter it to show only the rows you want, and cut those rows to the other sheets... after each cut operation, delete the blank rows... HTH Philip "Crowbar via OfficeKB.com" wrote: Hi All I have data in column A that says JN or HR or CH I want Excel to identify all data in column A and paste the data into a different sheet i.e All data that starts with JN in column A will be pasted into a JN sheet and all data that starts HR will go ito a sheet called HR Any Ideas?? -- Message posted via OfficeKB.com http://www.officekb.com/Uwe/Forums.a...mming/200512/1 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Cut and Paste range
Sub CopySortData()
Dim i As Integer, last As Integer, prefix As String last = ActiveSheet.Range("A65536").End(xlUp).Row For i = 1 To last prefix = Left(Cells(i, 1).Value, 2) If prefix < "" Then Worksheets(prefix).Cells(i, 1).Value = ActiveSheet.Cells(i, 1).Value End If Next i End Sub Works for me, though I'm sure you'll want to add refinements. -- Gordon Rainsford London UK "Crowbar via OfficeKB.com" <u15117@uwe wrote: Hi All I have data in column A that says JN or HR or CH I want Excel to identify all data in column A and paste the data into a different sheet i.e All data that starts with JN in column A will be pasted into a JN sheet and all data that starts HR will go ito a sheet called HR Any Ideas?? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
copy range and paste into every 3rd cell of new range | New Users to Excel | |||
Paste a named range to another range in Excel | Excel Discussion (Misc queries) | |||
Paste Small Range into Big Range | Excel Programming | |||
Range Cut and Paste | Excel Programming | |||
how do i paste a range? | Excel Programming |