Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Joanne wrote: Thanks for your input Sorry to say they do not work The subroutines work on the first set of 3 lines doing what is expected - then they grab the first line of the second set of 3 lines and place it in C3, and then the loop ends. Any ideas to fix this sure would be appreciated, as is your efforts so far. Again, thanks excelent wrote: Sub Xtst() Dim r, I r = Range("A1").CurrentRegion.Rows.Count For I = 1 To r Step 2 Cells(I, 2) = Cells(I + 1, 1) Cells(I, 3) = Cells(I + 2, 1) Next End Sub Try this one I think it should work for you Sub tst() Sheet1.Select Dim r As Integer Dim I As Integer Dim J As Integer J = 1 r = Sheet1.Range("A1").CurrentRegion.Rows.Count For I = 1 To r Sheet2.Cells(J + 1, 1).Value = Sheet1.Cells(I, 1).Value Sheet2.Cells(J + 2, 1).Value = Sheet1.Cells(I, 2).Value Sheet2.Cells(J + 3, 1).Value = Sheet1.Cells(I, 3).Value J = J + 3 Next I End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Making Data and Axis Labels Different | Charts and Charting in Excel | |||
Making Box Labels on UPS Thermal Using Excel. | Excel Discussion (Misc queries) | |||
making labels 'Easy to detect' | Excel Discussion (Misc queries) | |||
Data labels: Making the value currency & use % in a chart? | Charts and Charting in Excel | |||
Making Mailing Labels | Links and Linking in Excel |