Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Excel VBA > Excel VBA
|
Excel VBA Discuss using VBA for Excel programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Excel VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 27th, 2009, 03:04 AM
Authorized User
 
Join Date: Apr 2009
Posts: 23
Thanks: 1
Thanked 0 Times in 0 Posts
Default Populating an array from a filtered data

Dear all

I am finding a problem working with filtered range selection. Actually I want to populate an array with the filtered data. Here is my code that selects the filtered data but being new to array concepts, I want your help to figure out the code that could fill all the data for columns A thru J from the filtered data.

Sub intero()
Dim a, b As Single
Range("j65536").Select
a = 1
b = Range("j65530").End(xlUp).Row
Range("a" & a & ":j" & b).Copy
End Sub

Thanks in advance
 
Old July 27th, 2009, 07:47 AM
Friend of Wrox
 
Join Date: Sep 2005
Posts: 812
Thanks: 1
Thanked 53 Times in 49 Posts
Default

Hi

arTemp = Range("a" & a & ":j" & b)

will give you a [a x b] array

Cheers
Shasur
__________________
C# Code Snippets (http://www.dotnetdud.blogspot.com)

VBA Tips & Tricks (http://www.vbadud.blogspot.com)
 
Old July 27th, 2009, 12:44 PM
Authorized User
 
Join Date: Apr 2009
Posts: 23
Thanks: 1
Thanked 0 Times in 0 Posts
Default Thanks Shasur

Thanks a lot Shasur for your help like always. I will give it a try tomorrow morning and will get back to you should it requires your further assistance.Cheers :)





Similar Threads
Thread Thread Starter Forum Replies Last Post
Export to Excel only the filtered data Suresh62 Access VBA 0 May 23rd, 2008 10:26 AM
Filtered Sharepoint list, not filtered in infopath wmrdude SharePoint Development 0 July 26th, 2006 05:09 AM
populating an array from text box olddog VB.NET 2002/2003 Basics 1 July 27th, 2005 08:30 AM
using data filtered from asp.net page to generate ashutoshpandey31 Crystal Reports 0 March 12th, 2005 09:40 AM
Binding to Filtered Data (or Data subsets) gdbjohnson C# 8 August 27th, 2004 01:59 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.