Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Array to specific worksheet - nothing seems to work

I have tried everything but the array stubbornly refuses to populate
any sheet except the one the code belongs to:

Sub WontChangeWorksheetDestination()

Dim wks As Worksheet
Set wks = Sheets(3)

With wks

Set TheRange = Range(Cells(1, 1), Cells(10, 10))
TheRange.Value = MyArray

End With

End sub

I've tried everything, but because the code is behind a button on
sheet 1 the array populates sheet 1 and doesn't seem to want to
populate any toher sheet no mattwer hw I try to qualify it ... what am
I missing?

Any help gratefully accepted,

Kind regards, Mark
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,872
Default Array to specific worksheet - nothing seems to work

Hi,

Am Sun, 3 Jun 2012 10:29:01 -0700 (PDT) schrieb dial13:

With wks

Set TheRange = Range(Cells(1, 1), Cells(10, 10))
TheRange.Value = MyArray

End With


try:

With wks
Set TheRange = .Range(.Cells(1, 1), .Cells(10, 10))
TheRange.Value = MyArr
End With


Regards
Claus Busch
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Array to specific worksheet - nothing seems to work

Hi Claus,

Thanks for the help, that works, kind regards, Mark

On Monday, June 4, 2012 1:48:45 AM UTC+8, Claus Busch wrote:
Hi,

Am Sun, 3 Jun 2012 10:29:01 -0700 (PDT) schrieb dial13:

With wks

Set TheRange = Range(Cells(1, 1), Cells(10, 10))
TheRange.Value = MyArray

End With


try:

With wks
Set TheRange = .Range(.Cells(1, 1), .Cells(10, 10))
TheRange.Value = MyArr
End With


Regards
Claus Busch
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2


Reply
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
Find specific value in array of array formula DzednConfsd Excel Worksheet Functions 2 January 13th 09 06:19 AM
select range of specific hidden worksheet of closed protected work JASelep Excel Programming 0 September 6th 07 01:56 PM
Navigate to specific cell on specific worksheet Bryan Excel Programming 2 April 13th 06 04:33 PM
UDF to reference a specific element in an array GH[_2_] Excel Programming 4 January 8th 05 12:55 PM
Select an array of cells and paste to separate worksheet - 2nd post - 1st didn't work!! Lee Wold[_2_] Excel Programming 1 February 10th 04 03:22 PM


All times are GMT +1. The time now is 07:52 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"