From time to time the below '(pseudo) code takes awfully long for some printers (mostly printers connected to remote printservers)
VpeOpenDoc
VpeSetDevice
VpeDevEnumPaperBins
repeat x1 = 0 to vNumBins - 1:
VpeGetDevPaperBinID
VpeGetDevPaperBinName
end.
VpeCloseDoc
After restarting the windows Print Spool service on the computer that this code is running on, the code executes fast.
Does anybody have any experience in how to solve this?
Any info on how to troubleshoot what is "crashing" the Print Spool service?