#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 41
Default transpose data

I have data in column B from B2 to B3295 now I want to copy (Transpose) the
every 9 values in B column to one row, otherwords: b2: b10 change to c2 to k2
then B11 to B19 to c3 to k3 till the end.
I made something as below but it does not work can anybody please help.

Sub Transp()
Dim L As Long, i As Long, R As Long
R = 2
For L = 2 To 3295 Step 9
i = 2
Cells(R, i).Value = Cells(L + i, 3).Value
Next
End Sub
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 703
Default transpose data

Hi

I think this what your want to do:

Sub Transp()
Dim DestRow As Long, r As Long
DestRow = 2
For r = 2 To 3295 Step 9
Range(Cells(r, 2), Cells(r + 8, 2)).Copy _
Destination:=Cells(DestRow, 3)
DestRow = DestRow + 1
Next
End Sub

Regards,
Per

On 8 Maj, 15:42, Darius wrote:
I have data in column B from B2 to B3295 now I want to copy (Transpose) the
every 9 values in B column to one row, otherwords: b2: b10 change to c2 to k2
then B11 to B19 to c3 to k3 till the end.
I made something as below but it does not work can anybody please help.

Sub Transp()
Dim L As Long, i As Long, R As Long
R = 2
For L = 2 To 3295 Step 9
* *i = 2
* * * * Cells(R, i).Value = Cells(L + i, 3).Value
Next
End Sub


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 41
Default transpose data

thank you from both,

"Per Jessen" wrote:

Hi

I think this what your want to do:

Sub Transp()
Dim DestRow As Long, r As Long
DestRow = 2
For r = 2 To 3295 Step 9
Range(Cells(r, 2), Cells(r + 8, 2)).Copy _
Destination:=Cells(DestRow, 3)
DestRow = DestRow + 1
Next
End Sub

Regards,
Per

On 8 Maj, 15:42, Darius wrote:
I have data in column B from B2 to B3295 now I want to copy (Transpose) the
every 9 values in B column to one row, otherwords: b2: b10 change to c2 to k2
then B11 to B19 to c3 to k3 till the end.
I made something as below but it does not work can anybody please help.

Sub Transp()
Dim L As Long, i As Long, R As Long
R = 2
For L = 2 To 3295 Step 9
i = 2
Cells(R, i).Value = Cells(L + i, 3).Value
Next
End Sub



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,240
Default transpose data

Darius wrote:
I have data in column B from B2 to B3295 now I want to copy (Transpose) the
every 9 values in B column to one row, otherwords: b2: b10 change to c2 to k2
then B11 to B19 to c3 to k3 till the end.
I made something as below but it does not work can anybody please help.

Sub Transp()
Dim L As Long, i As Long, R As Long
R = 2
For L = 2 To 3295 Step 9
i = 2
Cells(R, i).Value = Cells(L + i, 3).Value
Next
End Sub



Put this in C2:K367

=INDIRECT("B"&(ROW()-2)*9+(COLUMN()-1))

then copy / paste special / values.
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Transpose Data No Idea[_2_] Excel Discussion (Misc queries) 0 August 21st 08 06:20 AM
transpose data Hilvert Scheper Excel Discussion (Misc queries) 5 May 30th 08 05:23 PM
Transpose data Nenagh Excel Discussion (Misc queries) 1 January 16th 08 05:22 AM
Transpose certain data BCLivell Excel Discussion (Misc queries) 1 November 7th 06 11:37 PM
transpose data babs Excel Worksheet Functions 2 December 7th 04 11:49 PM


All times are GMT +1. The time now is 07:50 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"