Teja
Teja

Reputation: 13544

How to transpose a column into a row in ms excel

I am trying to transpose a column into row in ms excel sheet.How can I do that? Do we have any command for doing this?Please help me.Thank you.

Upvotes: 1

Views: 608

Answers (2)

Andrew
Andrew

Reputation: 7788

if you want to transpose with VBA macro

Sub Trnspose()
    Dim wsSrc As Worksheet
    Dim wsDst As Worksheet

    Set wsSrc = Worksheets("Sheet1")
    Set wsDst = Worksheets("Sheet2")

    wsSrc.Range("A5:A8").Copy
    wsDst.Range("B2").PasteSpecial xlPasteValues, Transpose:=True

    Application.CutCopyMode = False

End Sub

Upvotes: 0

mooseman
mooseman

Reputation: 2017

Copy the data you want to transpose click on the cell you want the transposed data to start in (column A in the row?) click on the Home menu, then on the paste arrow (for more options) Then choose Transpose

Is this what you want or is there a VBA solution you are looking for?

Upvotes: 2

Related Questions