Set a 2D arrray data into a range, given the top-left cell
Hi all,
I hope to ask whether there is some convenient way to assign a 2D array data into a range by specifiying the top-left cell (e.g., A1). I'm looking for something like "CopyFromRecordset". Would any body have previous experience on that? Is the looping really necessary? Thanks a lot. Tom |
Set a 2D arrray data into a range, given the top-left cell
Tom,
Range("A1").Resize(UBound(MyArray, 1), UBound(MyArray, 2)).Value = MyArray -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "Tom Chau" wrote in message Hi all, I hope to ask whether there is some convenient way to assign a 2D array data into a range by specifiying the top-left cell (e.g., A1). I'm looking for something like "CopyFromRecordset". Would any body have previous experience on that? Is the looping really necessary? Thanks a lot. Tom |
Set a 2D arrray data into a range, given the top-left cell
Hi Jim,
It works very well. Thanks a lot. Tom Jim Cone wrote: Tom, Range("A1").Resize(UBound(MyArray, 1), UBound(MyArray, 2)).Value = MyArray -- Jim Cone San Francisco, USA http://www.realezsites.com/bus/primitivesoftware "Tom Chau" wrote in message Hi all, I hope to ask whether there is some convenient way to assign a 2D array data into a range by specifiying the top-left cell (e.g., A1). I'm looking for something like "CopyFromRecordset". Would any body have previous experience on that? Is the looping really necessary? Thanks a lot. Tom |
All times are GMT +1. The time now is 10:57 PM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com