How to read excel data column by column

How to read excel data column by column

m09366023695
Enthusiast Enthusiast
310 Views
1 Reply
Message 1 of 2

How to read excel data column by column

m09366023695
Enthusiast
Enthusiast

I'm using this code to get an excel data:

Set ws = oBook.Sheets("Sheet1")
 Set rngSize = ws.UsedRange

 Dim row As Range
        For Each row In rngSize.Rows
            Dim cell As Range
            For Each cell In row.Cells
                MsgBox cell.value
            Next cell
Next row

but it read data row by row. I want to read data column by column.

A1,A2,A3 etc.

B1,B2,B3 etc.

 

0 Likes
311 Views
1 Reply
Reply (1)
Message 2 of 2

Ed__Jobe
Mentor
Mentor

See my reply to your other Excel question.

Ed


Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.
How to post your code.

EESignature

0 Likes