Solved

Monitor print spooler

Posted on 2010-09-23
4
682 Views
Last Modified: 2012-05-10
I need a notification that alerts my application when the print spooler is stopped/restarted.  I have an application that uses FindFirstPrinterChangeNotification/FindNextPrinterChangeNotification and this works fine for the events I need to monitor.  However if the print spooler is stopped and restarted this stops working because the notification obect is no longer valid.  I need to be able to monitor the print spooler and when it restarts I can start again with FindFirstPrinterChangeNotification.  I can't seem to find anything that will do this.  Help please.  OS is server 2003/2008
0
Comment
Question by:PeterC_UK
  • 2
  • 2
4 Comments
 
LVL 30

Expert Comment

by:Brad Howe
ID: 33744060
what is the OS 2003 OR 2008?
You can create a triggered email event in 2008 to monitor the print spooler eventlog Event when it stops.
-Hades666
0
 

Author Comment

by:PeterC_UK
ID: 33744159
Thanks but it must work on 2003 as well and I need notification that enables my program to refresh automatically when the spooler starts

Peter
0
 
LVL 30

Accepted Solution

by:
Brad Howe earned 500 total points
ID: 33744189
Ok,
I would suggest requesting this moved to ASP.NET. A simple windows service that does the following.
Monitor Print Spooler.
Notify of it offline.
Restart your custom task/service.
Would be a better approach. You could also use SCOM (System Center Operations Manager) to monitor and automate but a simple windows service may be a better approach given your requirements.
Just a thought,
-Hades666
0
 

Author Closing Comment

by:PeterC_UK
ID: 33768199
Thanks - this pushed me in the right direction.  I solved it by using a named pipe from the InitializePrintMonitor2 call in a port monitor to notify my application that the spooler had started.
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
gpupdate /force to all workstations 4 46
Outlook creates tmp files 2 39
Problem to file 13 39
Reinstall Windows 10 3 14
NTFS file system has been developed by Microsoft that is widely used by Windows NT operating system and its advanced versions. It is the mostly used over FAT file system as it provides superior features like reliability, security, storage, efficienc…
When you start your Windows 10 PC and got an "Operating system not found" error or just saw  "Auto repair for startup" or a blinking cursor with black screen. A loop for Auto repair will start but fix nothing.  You will be panic as there are no back…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question