Application.Printers 100% CPU

C

Cheval

We recently installed the Hotfix KB895751 to allow MS Access to talk to Sql
Server 2005 tables which have GUIDs as primary keys. Since then the Access
Application.Printers object hangs Windows XP SP2 with the CPU running at 100%

Below is some sample code to reproduce the problem. In a new blank database,
add a new module and paste the code:

Public Sub MakeCrash()
On Error GoTo Err_MakeCrash

Dim Prt As Printer
Dim sDefault As String

sDefault = Application.Printer.DeviceName
MsgBox Application.Printers.Count
For Each Prt In Application.Printers
Next Prt

Exit_MakeCrash:
Set Prt = Nothing
Exit Sub

Err_MakeCrash:
MsgBox Err.Description, vbCritical + vbDefaultButton1 + vbOKOnly, "Form
- Sub MakeCrash"
Resume Exit_MakeCrash

End Sub

So does anyone have any ideas or is this a Microsoft support issue?
 

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