Trilight Zone Forum Index Trilight Zone
Privacy & Anonymity is our specialty !
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Getting Data on the Spooler Service

 
Post new topic   Reply to topic    Trilight Zone Forum Index -> windows
Author Message
digital8
Second Lieutenant


Joined: 29 Sep 2005
Posts: 1002

PostPosted: Fri Oct 07, 2005 12:36 pm    Post subject: Getting Data on the Spooler Service Reply with quote

Use this VB Script to get statistics on the printers assigned to the spooler service.

Copy and paste the following script (between the lines) into Notepad, making sure to have Word Wrap disabled, then save it with a .vbs extension.





On Error Resume Next
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from

Win32_PerfRawData_Spooler_PrintQueue",,4Cool
For Each objItem in colItems
Wscript.Echo "AddNetworkPrinterCalls: " & objItem.AddNetworkPrinterCalls
Wscript.Echo "BytesPrintedPersec: " & objItem.BytesPrintedPersec
Wscript.Echo "Caption: " & objItem.Caption
Wscript.Echo "Description: " & objItem.Description
Wscript.Echo "EnumerateNetworkPrinterCalls: " &

objItem.EnumerateNetworkPrinterCalls
Wscript.Echo "Frequency_Object: " & objItem.Frequency_Object
Wscript.Echo "Frequency_PerfTime: " & objItem.Frequency_PerfTime
Wscript.Echo "Frequency_Sys100NS: " & objItem.Frequency_Sys100NS
Wscript.Echo "JobErrors: " & objItem.JobErrors
Wscript.Echo "Jobs: " & objItem.Jobs
Wscript.Echo "JobsSpooling: " & objItem.JobsSpooling
Wscript.Echo "MaxJobsSpooling: " & objItem.MaxJobsSpooling
Wscript.Echo "MaxReferences: " & objItem.MaxReferences
Wscript.Echo "Name: " & objItem.Name
Wscript.Echo "NotReadyErrors: " & objItem.NotReadyErrors
Wscript.Echo "OutofPaperErrors: " & objItem.OutofPaperErrors
Wscript.Echo "References: " & objItem.References
Wscript.Echo "Timestamp_Object: " & objItem.Timestamp_Object
Wscript.Echo "Timestamp_PerfTime: " & objItem.Timestamp_PerfTime
Wscript.Echo "Timestamp_Sys100NS: " & objItem.Timestamp_Sys100NS
Wscript.Echo "TotalJobsPrinted: " & objItem.TotalJobsPrinted
Wscript.Echo "TotalPagesPrinted: " & objItem.TotalPagesPrinted
Next
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Trilight Zone Forum Index -> windows All times are GMT
Page 1 of 1

 


Powered by phpBB © 2001, 2005 phpBB Group