ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Range doesn't fill (https://www.excelbanter.com/excel-programming/300219-range-doesnt-fill.html)

JWolf

Range doesn't fill
 
I have the following line in my code:

Worksheets("Sheet5").Range(Cells(2, 1), Cells(fnshcnt + 1, 16)) = reslist

where fnshcnt=46 and reslist is an (46,16) array, both are correct in a
watch window when the code is paused immediately before this line.

The code works in a workbook from yesterday, filling the correct cells,
A2:P47.

I started a new workbook today, attempting to strip out some bloat built
up over the years. No protection is enabled on any sheet. File size is
reduced almost 50% ~600K to ~300K.

On the new workbook using the same data as the original, fnshcnt and
reslist show the same values immediately before the line in question.
The rest of the code functions properly.

Only cells A2:K2 get filled.

Any clues as to what is happening?

JWolf

Range doesn't fill
 
Ignore previous. Somehow a date literal got into the array, wouldn't
transfer.

JWolf wrote:

I have the following line in my code:

Worksheets("Sheet5").Range(Cells(2, 1), Cells(fnshcnt + 1, 16)) = reslist

where fnshcnt=46 and reslist is an (46,16) array, both are correct in a
watch window when the code is paused immediately before this line.

The code works in a workbook from yesterday, filling the correct cells,
A2:P47.

I started a new workbook today, attempting to strip out some bloat built
up over the years. No protection is enabled on any sheet. File size is
reduced almost 50% ~600K to ~300K.

On the new workbook using the same data as the original, fnshcnt and
reslist show the same values immediately before the line in question.
The rest of the code functions properly.

Only cells A2:K2 get filled.

Any clues as to what is happening?



All times are GMT +1. The time now is 07:20 PM.

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