HELP! Do While...Loop slower as it proceeds???

H

Haettner

I have a Do While...Loop processing an array of 8500
records. Each record is transferred to a single row in
another workbook. A number of procedures is processed on
each row and then next record is transferred. Look at the
data below!

Why is this happening??? The speed is excellent the first
5 minutes but then its a disaster! Is Excel "eating"
memory? Is it possible to allocate memory, if that is the
problem, by some method in VBA? Or.....?

I would be VERY happy to a solution!

/jonas haettner

Time No of processed records Records/min
0 - 5 min 3700 750
5 - 10 min 4575 163
10 - 16 min 5392 136
16 - 21 min 5970 116
21 - 26 min 6486 103
26 - 31 min 6957 94
31 - 36 min 7377 84
36 - 41 min 7800 85
41 - 46 min 8190 77
46 - klart 8420
 
D

Dave Peterson

When you transfer the row, do you delete the original?

And if you do delete, do you have those little dotted lines that show where the
automatic page breaks are?

If yes, then try turning them off.
Tools|options|View tab|uncheck page breaks

Then run your macro. If it's quicker, then you can add a line of code to the
top of your macro that turns off the page break display:

ActiveSheet.DisplayPageBreaks = False

(adjust the sheet reference)
 
G

Guest

It's a lot of code in different modules and I think it
would be very difficult to get an overview here. Is it
possible for me to send you my excelfile with the original
code?

Or perhaps copy the code into NotePad, MS Word...?

Please respond to this!

/jonas
 
D

Don Guillett

Can't you just copy part of it to a reply? Or, more fully describe the
situation.
If not, and the file is SMALL (on 56k modem), send to (e-mail address removed)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top