Excel transpose column value into row --head scratcher Hi there, I previously po
ID: 3570937 • Letter: E
Question
Excel transpose column value into row --head scratcher
Hi there,
I previously posted a question that may be too big for folks to understand or be able to help me with
so I thought I would post the key part of my problem that I am having the most problem with.
I feel that if I can get VBA help on this "key" step then the rest I can figure out.
I have a table that I would like to covert the column info into row format as shown below.
I'm not sure how to do this. Any help that folks can offer would be very much appreciated!
I have searched the web for anything similar to this problem but haven't been able to find
one although I'm not sure how to describe what I am trying to do other than to show it.
Thanks for help !!
Excel transpose column value into row --head scratcher Hi there, I previously posted a question that may be too big for folks to understand or be able to help me with so I thought I would post the key part of my problem that I am having the most problem with. I feel that if I can get VBA help on this ''key'' step then the rest I can figure out. I have a table that I would like to covert the column info into row format as shown below. I'm not sure how to do this. Any help that folks can offer would be very much appreciated! I have searched the web for anything similar to this problem but haven't been able to find one although I'm not sure how to describe what I am trying to do other than to show it. Thanks for help !!Explanation / Answer
Hi..
Assuming that the data begin in cell A1:
Dim wshS As Worksheet
Dim wshT As Worksheet
Dim s As Long
Dim m As Long
Dim t As Long
Application.ScreenUpdating = False
Set wshS = ActiveSheet
Set wshT = Worksheets.Add(After:=wshS)
wshT.Range("A1") = "AccountNumber"
wshT.Range("B1") = "WorkOrderNOs"
wshT.Range("C1") = "WorkOrderPER Value"
m = wshS.Range("A" & wshS.Rows.Count).End(xlUp).Row
t = 1
For s = 2 To m
t = t + 1
wshT.Range("A" & t) = wshS.Range("A" & s)
wshT.Range("B" & t) = wshS.Range("B" & s)
wshT.Range("C" & t) = wshS.Range("D" & s)
t = t + 1
wshT.Range("A" & t) = wshS.Range("A" & s)
wshT.Range("B" & t) = wshS.Range("C" & s)
wshT.Range("C" & t) = wshS.Range("E" & s)
Next s.
Applicationn.ScreenUpdating = True.
End Sub.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.