Slows after about 1,000 records?

P

Paul H

I am creating an XLS file from a CSV file using COBOL Net Express, adding
one record at a time. I use various INVOKE statements. After about 1,000
records the speed drops to about 1/4 of the prior rate per minute. I doubt
that the speed of reading the input file changes. Is this because of an
Excel overflow buffer issue? How can I fix this? TIA, Paul
 
J

jaf

Hi Paul,
Perhaps. More likely a windows problem.
Your code could be hogging the processor.
In VBA we would put a DOEVENTS after X reads to allow windows to catch up on other business.

Don't know if Cobol has an similar statement.

John
 
P

Paul H

Thanks John,
That sounds reasonable - my program does a lot of computing. But won't that
solution just let the program run as slowly - just breaking up who is doing
the processing when? And why would it wait until 1,000 records before the
effect starts?


Hi Paul,
Perhaps. More likely a windows problem.
Your code could be hogging the processor.
In VBA we would put a DOEVENTS after X reads to allow windows to catch up on
other business.

Don't know if Cobol has an similar statement.

John


I am creating an XLS file from a CSV file using COBOL Net Express, adding
one record at a time. I use various INVOKE statements. After about 1,000
records the speed drops to about 1/4 of the prior rate per minute. I doubt
that the speed of reading the input file changes. Is this because of an
Excel overflow buffer issue? How can I fix this? TIA, Paul
 
J

jaf

Hi Paul,
If you were to write a tight endless loop, Windows pending tasks & events pile up in a queue.
I've seen app's that can stop the updating of the system clock causing the clock to "lose time".
Allowing Windows to clear it's queue frees up resources.

John
 

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