Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Faster way to do this?
I periodically extract data from report files to populate a worksheet.
Every week or so, I rerun this to create an updated workbook. It's starting to get rather large - each update adds a few more new rows. My problem is that the data in any row can change from the previous workbook. I can check for changes by comparing the values of certain cells between the workbooks. Right now, the method I'm thinking of would look like: For Each cell in Book1ColA Get Book1ColA Value Get Book1ColA Row# Find Book1ColA Value in Book2ColA Get Book2ColA Row# If Value Book1ColC Row# < Value Book2ColC Row# Then MsgBox or something End If Next cell Is there a faster way to accomplish this, versus iterating through every cell in the column? Ed |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Faster way to do this?
Ed,
I don't think there is a faster approach than comparing each cell; however, you can make the comparison (much) faster by reading the data (ranges) into arrays and comparing the arrays rather than looping through the ranges. HTH "Ed" wrote: I periodically extract data from report files to populate a worksheet. Every week or so, I rerun this to create an updated workbook. It's starting to get rather large - each update adds a few more new rows. My problem is that the data in any row can change from the previous workbook. I can check for changes by comparing the values of certain cells between the workbooks. Right now, the method I'm thinking of would look like: For Each cell in Book1ColA Get Book1ColA Value Get Book1ColA Row# Find Book1ColA Value in Book2ColA Get Book2ColA Row# If Value Book1ColC Row# < Value Book2ColC Row# Then MsgBox or something End If Next cell Is there a faster way to accomplish this, versus iterating through every cell in the column? Ed |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
can this be done faster? | Excel Discussion (Misc queries) | |||
Can faster CPU+larger/faster RAM significantly speed up recalulati | Excel Discussion (Misc queries) | |||
better/faster way than sum products? | Excel Worksheet Functions | |||
Is there a faster way | Excel Programming | |||
Which one is faster? | Excel Programming |