ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Macro Help (https://www.excelbanter.com/excel-programming/436612-macro-help.html)

Neil Holden

Macro Help
 
Below is the code to insert data require into another excel workbook, it is
pasting it vertical as in a1 a2 a3 etc i need it to paste a1 b1 c1 etc.
Please help.

lngRow = wsDest.Cells(Rows.Count, "A").End(xlUp).Row + 1

wsDest.Range("A" & lngRow).Resize(rngTemp.Rows.Count, _
rngTemp.Columns.Count) = rngTemp.Value

End With

wbBook.Close True


Jacob Skaria

Macro Help
 
Neil; why dont you try recording a macro with transpose and modify your code
to suit..

If this post helps click Yes
---------------
Jacob Skaria


"Neil Holden" wrote:

Below is the code to insert data require into another excel workbook, it is
pasting it vertical as in a1 a2 a3 etc i need it to paste a1 b1 c1 etc.
Please help.

lngRow = wsDest.Cells(Rows.Count, "A").End(xlUp).Row + 1

wsDest.Range("A" & lngRow).Resize(rngTemp.Rows.Count, _
rngTemp.Columns.Count) = rngTemp.Value

End With

wbBook.Close True



All times are GMT +1. The time now is 10:17 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com