PC Review


Reply
Thread Tools Rate Thread

copy worksheet to array

 
 
Kalle
Guest
Posts: n/a
 
      9th Oct 2008

Hi

I know that it is possible to copy a array t o a worksheet but I can't
find out if it's possible to copy a worksheet into an arry?

Thanks in advance

*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
 
Joel
Guest
Posts: n/a
 
      9th Oct 2008
You can copy a Range into an array using the varue property like

myarray = Range("A1:F10").value


"Kalle" wrote:

>
> Hi
>
> I know that it is possible to copy a array t o a worksheet but I can't
> find out if it's possible to copy a worksheet into an arry?
>
> Thanks in advance
>
> *** Sent via Developersdex http://www.developersdex.com ***
>

 
Reply With Quote
 
Gary Keramidas
Guest
Posts: n/a
 
      9th Oct 2008
this may be what you're looking for

Sub test()
Dim ws As Worksheet
Dim arr As Variant
Dim rng As Range
Set ws = Worksheets("Sheet1")
arr = ws.Range("A1:P1000")

End Sub


--


Gary

"Kalle" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
>
> Hi
>
> I know that it is possible to copy a array t o a worksheet but I can't
> find out if it's possible to copy a worksheet into an arry?
>
> Thanks in advance
>
> *** Sent via Developersdex http://www.developersdex.com ***



 
Reply With Quote
 
Kalle
Guest
Posts: n/a
 
      9th Oct 2008


Thanks a lot for your replay. It now works as I want.

*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: Efficient Code to Copy a 1-D Array to a Worksheet Column Tom Ogilvy Microsoft Excel Programming 4 7th Dec 2006 04:27 PM
Array.Copy and Cloning an array don't seem to work differently illegal.prime@gmail.com Microsoft Dot NET Framework 1 29th Aug 2006 12:13 AM
Array.Copy and Cloning an array don't seem to work differently illegal.prime@gmail.com Microsoft C# .NET 1 29th Aug 2006 12:13 AM
ReDim Variant array for worksheet copy =?Utf-8?B?Sm9obiBLZWl0aA==?= Microsoft Excel Programming 1 16th Feb 2006 09:52 PM
select variables ranges, copy to array, paste the array in new workbook Mathew Microsoft Excel Worksheet Functions 1 1st Apr 2005 09:40 AM


Features
 

Advertising
 

Newsgroups
 


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