PC Review


Reply
Thread Tools Rate Thread

how to build a dynamic array and search it for a value

 
 
michael.beckinsale
Guest
Posts: n/a
 
      11th May 2009
Hi All,

What l want to do is to copy rows from 'source' workbooks and append
to a 'master' workbook but only rows where the unique reference does
not already exist in the 'master' workbook. The source & master
workbooks are identical in layout and the unique identifier is in
column A.

I have used the code generously given by Ron De Bruin to loop through
all the source workbooks and all works fine but l am stumped as to the
best way to achieve the above efficiently without going down the
Access / SQL route.

My thoughts were to build an array from column A of the 'master'
workbook and then loop through each row of column A of the 'source'
workbook copying the data if the cell(r,"A").Value was in the array.

Can anybody point me in the right direction with some sample code to:

1) Build the 'master' workbook array
2) Check that the current 'source' record idnetifier exists in the
array

Alternatively suggest a better / quicker method with some example
code. There is likely to be approx 12 workbooks with 300 rows /
records in each. VBA code needs to be compatible with XL2003 & XL2007.

TIA

All help suggestions greatly appreciated.

Regards

Michael

 
Reply With Quote
 
 
 
 
Bernd P
Guest
Posts: n/a
 
      11th May 2009
Hello Michael,

Maybe my UDF's at
http://www.sulprobil.com/html/listfreq.html
can help you. Lfreq, for example.

Regards,
Bernd
 
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
Dynamic search criteria from an array? Joe M. Microsoft Access 1 17th Mar 2009 02:33 PM
Speed of fixed array versus dynamic array Sing Microsoft Excel Programming 8 18th Nov 2007 10:19 AM
Dynamic Array Lbound not working when only one value in array dean.brunne@lion-nathan.com.au Microsoft Excel Programming 3 25th May 2007 04:08 AM
Build a dynamic array from DataReader... Brent Microsoft ASP .NET 1 28th Sep 2005 10:59 PM
dynamic array of pointers vs dynamic array of objects lemonade Microsoft VC .NET 1 10th Dec 2003 08:31 PM


Features
 

Advertising
 

Newsgroups
 


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