LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 175
Default Problem assigning values to a range of cells

The first line works fine to set the block of cells...
Why won't the 2nd line work? (results are all cells are blank, the "1"'s
all get wiped out)

Range("F3:H6").Value = "1"
Range("F3:H6").Value = Array(Array("1", "2", "3"), Array("4", "5", "6"),
Array("7", "8", "9"), Array("10", "11", "12"))

2nd line should all be on 1 line in the VBE; I also tried making the data
just integers... Array(1,2,3).... but that did the same thing.

What is the best/better way to assign a user-type module level multidim
array to a contiguous block of cells? Using a loop to scroll through the 2
dimensions and assigning each value to a cell (via range.offset.value) sure
seems slow (even with screen updating off and calculation off)

Is there a way to set up the definition of an array that can be directly
assigned to a range of cells?
I.E:
[F3:H6] = myarray
Where myarray matches the cell blocks in dimension.

--
Regards,
John
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
problem assigning range returned by function, to combobox rowsource Kate Excel Programming 6 August 26th 05 02:28 PM
Assigning ranges for values (e.g., $1,005 the range is ">$1K to 5K jennifer Excel Worksheet Functions 1 August 11th 05 02:09 PM
problem with Paste-Special-Values from a List (range of cells) crimsonkng Excel Programming 1 June 1st 05 09:51 PM
Problem with assigning values to items in collection Jurry[_12_] Excel Programming 0 May 12th 04 09:18 PM
Assigning values from a selected range to individual variables Dr. Schwartz[_3_] Excel Programming 5 January 27th 04 02:27 PM


All times are GMT +1. The time now is 12:07 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"