ADRIANA P
asked on
NEED TRANSFER DATA
ASKER
MARTIN
CAN BE A NEW SHEET TOO
LET'S SAY I CAN PASTE THE DATA
IN A NEW WOORKBOOK WITH AN SHEET A COLUMN A P LASTE THERE
AND A NEW SHEET B CAN BE THE RESULTS
CAN BE A NEW SHEET TOO
LET'S SAY I CAN PASTE THE DATA
IN A NEW WOORKBOOK WITH AN SHEET A COLUMN A P LASTE THERE
AND A NEW SHEET B CAN BE THE RESULTS
ASKER
excuse me about the caps on
You may try something like this...
Click the button on Sheet1 to run the below macro to get the desired output on a separate sheet called Output. This sheet will be inserted by the macro if not present in the workbook.
Click the button on Sheet1 to run the below macro to get the desired output on a separate sheet called Output. This sheet will be inserted by the macro if not present in the workbook.
Sub TransposeData()
Dim sws As Worksheet, dws As Worksheet
Dim slr As Long, c As Long
Dim Rng As Range
Application.ScreenUpdating = False
Set sws = Sheets("Sheet1")
slr = sws.Cells(Rows.Count, 5).End(xlUp).Row
On Error Resume Next
Set dws = Sheets("Output")
dws.Cells.Clear
On Error GoTo 0
If dws Is Nothing Then
Sheets.Add(after:=sws).Name = "Output"
Set dws = ActiveSheet
End If
For Each Rng In sws.Range("E7:E" & slr).SpecialCells(xlCellTypeConstants, 2).Areas
c = c + 1
dws.Cells(1, c).Value = Rng.Cells(1).Offset(-1, -1).Value
Rng.Offset(-1, 0).Resize(Rng.Cells.Count + 1, 1).Copy dws.Cells(2, c)
Next Rng
dws.Rows(1).HorizontalAlignment = xlCenter
Application.ScreenUpdating = True
End Sub
CHANGE-FOR-ANALYSIS.xlsm
Try my workbook and let me know what needs changing.
Make sure you are looking at Sheet1 and then press and hold the Control and Shit keys and press the "S" key. Then look at sheet2.
This version has a "Transfer" button.
29011545a.xlsm
29011545a.xlsm
ASKER
MARTIN IS ALMOST DONE
BUT
IS EVERY 12 RANGE
1 IS BLANK
2 TO 13 IS DATA
AND BEGING AGAIN
1 IS BLANK
2 TO 13 IS DATA
BUT
IS EVERY 12 RANGE
1 IS BLANK
2 TO 13 IS DATA
AND BEGING AGAIN
1 IS BLANK
2 TO 13 IS DATA
ASKER
Subodh Tiwari (Neeraj) for you promplty answer
almost work but i ahve over 3000 records
and anfert column 10 phase out the data
have to be in ranges of 13
1 blank
2
to
13 data
and beging again
1 blank
2 to 13 data
almost work but i ahve over 3000 records
and anfert column 10 phase out the data
have to be in ranges of 13
1 blank
2
to
13 data
and beging again
1 blank
2 to 13 data
My results are exactly what you show in the example (except for the columns).
Hi Adriana,
Do you want to have max 10 columns of transposed data on one sheet and then start over again transposing the data on the new sheet?
Do you want to have max 10 columns of transposed data on one sheet and then start over again transposing the data on the new sheet?
ASKER
maritn this is what happens
trans.png
trans.png
ASKER
Subodh Tiwari (Neeraj)
lets see...
lets see...
Still hard to guess your end result.
BTW try this to see if this is what you are trying to achieve here.
BTW try this to see if this is what you are trying to achieve here.
Sub TransposeData()
Dim sws As Worksheet, dws As Worksheet
Dim slr As Long, c As Long, i As Long
Dim Rng As Range
Application.ScreenUpdating = False
Set sws = Sheets("Sheet1")
slr = sws.Cells(Rows.Count, 5).End(xlUp).Row
c = 1
i = 1
For Each Rng In sws.Range("E7:E" & slr).SpecialCells(xlCellTypeConstants, 2).Areas
If c = 1 Then
On Error Resume Next
Set dws = Sheets("Output" & i)
dws.Cells.Clear
On Error GoTo 0
If dws Is Nothing Then
Sheets.Add(after:=Sheets(Sheets.Count)).Name = "Output" & i
Set dws = ActiveSheet
End If
End If
dws.Cells(1, c).Value = Rng.Cells(1).Offset(-1, -1).Value
Rng.Offset(-1, 0).Resize(Rng.Cells.Count + 1, 1).Copy dws.Cells(2, c)
c = c + 1
If c > 10 Then
c = 1
i = i + 1
Set dws = Nothing
End If
Next Rng
Application.ScreenUpdating = True
End Sub
If you want column A to be blank on all the new sheets, change all the occurrences of c = 1 with c = 2.
ASKER
this is what have to be
trans233.png
trans233.png
Can you upload a sample workbook with the desired output mocked up manually as the images you have uploaded so far don't help much as we cannot see the row numbers and column letters so not sure about the exact position of data on the sheet?
ASKER
martin the file you post to me don't works like that
can you verify please !!
will be great if work like that
here the data i need to work on if help to get the result
DATA-ON.xlsx
can you verify please !!
will be great if work like that
here the data i need to work on if help to get the result
DATA-ON.xlsx
ASKER
Subodh Tiwari (Neeraj)
this is what aiget with the code you send me
it don't put the data on teh ranges of 13
transpo-c.png
this is what aiget with the code you send me
it don't put the data on teh ranges of 13
transpo-c.png
ASKER
here what's should comes out please verify
rigth-data.png
rigth-data.png
Adrianna, the data on the left side of that picture does not agree with the data on the right side.
In the workbook you posted, please tell me what rows should be in column "M" and what rows should be in column "N".
In the workbook you posted, please tell me what rows should be in column "M" and what rows should be in column "N".
Well it is still not clear.
Anyways find the attached and click the button to run the code.
And if this is not your desired end result, change the output on the newly added sheets and upload the workbook here.
DATA-ON.xlsm
Anyways find the attached and click the button to run the code.
And if this is not your desired end result, change the output on the newly added sheets and upload the workbook here.
DATA-ON.xlsm
ASKER
Subodh Tiwari (Neeraj)
now i get a lot of diferrents sheets with outputs
i need just one sheet output but
the data from one column should be put in 13 rows format all the way along
aloaoutput.png
now i get a lot of diferrents sheets with outputs
i need just one sheet output but
the data from one column should be put in 13 rows format all the way along
aloaoutput.png
Can you mock up the desired output based on your sample file and show us what do you need exactly?
ASKER
ok i m learning
The data under "1" in the left hand side (blank, 824, 705, etc.) does not agree with the data you show under "1" on the right hand side (blank, 417, 279, etc.)
Okay can you check the attached and confirm?
DATA-ON.xlsm
DATA-ON.xlsm
ASKER
Matin i see sorry
you rigth on that
excus me for the confusion
but like i say one column data
to be in 13 ranges with the first blank 2 to 13 with the data and all over
you rigth on that
excus me for the confusion
but like i say one column data
to be in 13 ranges with the first blank 2 to 13 with the data and all over
What about this?
DATA-ON.xlsm
DATA-ON.xlsm
first blank 2 to 13 with the data and all overI know that the first cell in each set will be blank, but will the 2 to 13 part ever have blank cells. If it does do you want to see the blank cells on the right?
ASKER
ok good question !
martin
yes when one blank shoud be there too with not data in but in the same space
13 set
1 blank
2
to
13 with the data
is equal to say 12 data column
but the 1 blank
pull apart the data in the short column
martin
yes when one blank shoud be there too with not data in but in the same space
13 set
1 blank
2
to
13 with the data
is equal to say 12 data column
but the 1 blank
pull apart the data in the short column
ASKER
iput inthe same place i mean
Did you check the file I uploaded?
ASKER
Subodh Tiwari
almost work but
is taking 13
remember 13 is with first blank and 12 with data
1=blank
2
to
13 with data
is equal to 12 data but first blank to separate
almost work but
is taking 13
remember 13 is with first blank and 12 with data
1=blank
2
to
13 with data
is equal to 12 data but first blank to separate
I'm sorry but I don't understand what you said. Given this data
824
705
750
232
316
949
240
377
251
719
548
841
065
744
023
857
990
310
530
666
099
822
958
226
179
623
720
748
828
421
746
140
what should be in column "M" and what should be in column "N"?
824
705
750
232
316
949
240
377
251
719
548
841
065
744
023
857
990
310
530
666
099
822
958
226
179
623
720
748
828
421
746
140
what should be in column "M" and what should be in column "N"?
Did you check the file I uploaded in the following post?
https://www.experts-exchange.com/questions/29011545/NEED-TRANSFER-DATA.html?anchor=a42063833¬ificationFollowed=186366466&anchorAnswerId=42063805#a42063805
https://www.experts-exchange.com/questions/29011545/NEED-TRANSFER-DATA.html?anchor=a42063833¬ificationFollowed=186366466&anchorAnswerId=42063805#a42063805
ASKER
matin
don't have to be in column m or n
don't have to be in column m or n
ASKER
Martin
could be an blank workbook so i can paste there from the original!
you can put set it so i can use coumn A
could be an blank workbook so i can paste there from the original!
you can put set it so i can use coumn A
I don't care what the output columns are. What should be in the first output column and what should be in the second output column?
ASKER
you can set it so i can move the data when is ready
I don't care what the output columns are. What should be in the first output column and what should be in the second output column?Please answer that question using this data which is from your workbook.
824
705
750
232
316
949
240
377
251
719
548
841
065
744
023
857
990
310
530
666
099
822
958
226
179
623
720
748
828
421
746
140
ASKER
Ok Martin Great !
824 should be in first column 065 second column 958 third column
824 should be in first column 065 second column 958 third column
Two Great Experts here, and still taking so long? LOL
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Martin Sir,
I have different approach, If you can play around with my code to make it Column wise.
DATA-ON_v3.xlsm
I have different approach, If you can play around with my code to make it Column wise.
DATA-ON_v3.xlsm
ASKER
The best !
ASKER
Martin ! Great Expert !
thats what i need !
thats what i need !
Give me a minute and I think I can speed it up.
Martin Sir,
Still its not perfect. Please check again.
Still its not perfect. Please check again.
There are many columns which are not pulling right data.
ASKER
Subodh Tiwari you was so close may be don't have time but very good too !
thanks to you too!
thanks to you too!
ASKER
yes is not perfect ! but very closed ! to be
This takes about 8 seconds.
29011545c.xlsm
29011545c.xlsm
ASKER
thge blank data is because have some empty fields in the 12 cycle
there are 12 but the first is the begining of the next
there are 12 but the first is the begining of the next
ASKER
if youcan speed an d make better will be nice !
Please see the 29011545c version I posted above.
To see the results, go to Sheet1 and press Ctrl+Shift+S
29011545.xlsm