Transponse the data from vertical to horizondal using vba

Posted by raam on Stack Overflow See other posts from Stack Overflow or by raam
Published on 2010-05-29T06:16:16Z Indexed on 2010/05/29 6:22 UTC
Read the original article Hit count: 177

Filed under:

I wants to popualte the data in MS-Access into Excel for this i am using VBA This is my code varConnection = "ODBC; DSN=MS Access Database;DBQ=D:\sample\table.accdb; Driver={Driver do Microsoft Access (*.accdb)}"

   varSQL = "SELECT * FROM LeftPanes"
   With ActiveSheet.QueryTables.Add(Connection:=varConnection, Destination:=ActiveSheet.Range("B4"))
           .CommandText = varSQL
           .Name = "Query-39008"
           .Refresh BackgroundQuery:=False
   End With

Its working Properly it retrive data and display in the correct sheet my problem is that this code display the retrived date in vertically view i needs horizondal view. it is possible to display in horizondal view please any one guide me . Thanks in advance

© Stack Overflow or respective owner

Related posts about outlook-vba