Slow database access after printing.

A

arildp

I'm testing a simple VBA code which reads data from Access and displays it in
an Excel worksheet. Everything works fine until I print the sheet(Print/Print
preview or Cute PDF).
After printing, the DB access becomes painfully slow and Excel and spoolsv
are using 40-50% CPU. The cure is to Exit and reopen the worksheet.
I can observe that Excel continues to use the spool directory after
printing, but do not understand why this happens - printer driver ?
I have Excel 2002, Windows XP SP2 and a Canon iP200 printer, but the same
thing happens on my Windows 2000 conputer (same printer).

Filemon example when retreving data (after printing):
EXCEL.EXE:2616 FASTIO_QUERY_STANDARD_INFO
C:\WINDOWS\System32\spool\DRIVERS\COLOR\CNBJPRN2.ICM SUCCESS Length: 17372

EXCEL.EXE:2616 IRP_MJ_CLOSE
C:\WINDOWS\System32\spool\DRIVERS\COLOR\CNBJPRN2.ICM SUCCESS
spoolsv.exe:1440 IRP_MJ_CREATE C:\WINDOWS\System32\spool NAME COLLISION
Options: Create Directory Access: All
spoolsv.exe:1440 IRP_MJ_CREATE C:\WINDOWS\System32\spool\DRIVERS NAME
COLLISION Options: Create Directory Access: All
spoolsv.exe:1440 IRP_MJ_CREATE C:\WINDOWS\System32\spool\DRIVERS\W32X86 NAME
COLLISION Options: Create Directory Access: All

Anybody having a suggestion what is going on and how to get around this
annoying issue ?

Arild Prestvik
Norway
 
A

arildp

I have to rephrase the problem after a little more investigation:
The delay occurs when writing to the Excel sheet, not in the database access.
When I stop the spooler, output is ok. After starting the spooler, it's
terrible slow until I quit and open the workbook again.
So once I have printed or previewed a sheet, it looks like Excel continues
to use the spooler to "print" data to the Excel sheet - a spoolsv issue ?
I'm stuck !
 

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