LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 536
Default Process dumped into an array...and then back to sheet

As is, this code takes about 38 seconds to process just over 1 million rows.. Maybe that ain't too bad but I see GS, Claus, Isabelle et. al., speak of "...dumping into an array and when finished dumping back to the sheet..." or words to that affect to speed up processing a great deal.

I give myself credit to be smart enough to ask the question and bear full responsibility for being too dumb to be able to do it.

Here I'm taking a string (happens to be a set of digits) from MID and comparing with an equal length string of digits from RIGHT for a true or false return.

Option Explicit
Sub tester()
Dim c As Range
Application.ScreenUpdating = False
'c.Offset(0, 8) = "'" & Mid$(c, 8, 13)
'c.Offset(0, 9) = "'" & Right$(c, 13)
For Each c In Range("E1:E" & Range("E" & Rows.Count).End(xlUp).Row)
If Mid$(c, 8, 13) = Right$(c, 13) Then
c.Offset(0, 7).Value = "TRUE"
Else
c.Offset(0, 7).Value = "FALSE"
End If
Application.ScreenUpdating = True
Next
End Sub

Thanks.
Howard
 
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
Array takes 6x longer to process VLOOKUP than worksheet table does KGOldWolf Excel Programming 3 November 5th 09 03:49 PM
Macro suddenly stops mid process through an array [email protected] Excel Programming 4 October 31st 08 01:59 PM
How do I create a process sheet? soconfused Excel Discussion (Misc queries) 2 September 25th 07 04:54 PM
Extract all CN='Name' from a Active Directory data-dumped-cell mateo561 Excel Programming 7 December 7th 06 08:32 AM
Chart is being dumped into the wrong sheet poppy Excel Programming 5 July 29th 04 11:52 PM


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