![]() |
|
|
|||||||
| Petri.co.il is happy to award auglan the title of Most Valuable Member !!! |
| Register | Calendar |
Search |
Today's Posts |
Mark Forums Read |
| Notices |
|
|
Reading Application and Services Log Win2K8R2this thread has 2 replies and has been viewed 905 times
|
![]() |
|
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
||||||||
|
||||||||
|
Hi,
We are trying to read print events from our Win2K8 print server by adapting a script we have been using for Win2K3. This is the code we are using to read the System event log Code:
# Retrieve the event log and entries
$EventLog=[System.Diagnostics.EventLog]::GetEventlogs($servername)
$Systemlog = $EventLog |? {$_.log -eq 'System'}
$events = $SystemLog.Entries | Where {$_.eventid -eq 10 -AND $_.Source -eq "Print" -AND $_.Timegenerated -gt (Get-Date).adddays(-1) } | select Username, Timegenerated, Message
How can I read from this section as my google searching seems to be failing. Thanks |
|
#2
|
||||||||||
|
||||||||||
|
__________________
Tom Jones MCT, MCSE (2000:Security & 2003), MCSA:Security & Messaging, MCDBA, MCDST, MCITP(EA, EMA, SA, EDA, ES, CS), MCTS, MCP, Sec+ PhD, MSc, FIAP, MIITT IT Trainer / Consultant Ossian Ltd Scotland ** Remember to give credit where credit is due and leave reputation points where appropriate ** |
|
#3
|
||||||||
|
||||||||
|
Thanks for that, not sure how I missed that, but have noticed a problem with the event viewer, but will post in the 2008 thread as it is not to do with powershell.
Thanks Dave |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Adding a new Win2K8R2 DC to an existing Win2K3 site | JDMils | Active Directory | 1 | 25th July 2012 11:43 |
| Ex2003 Problem post Win2k8R2 install | wolfr1 | Exchange 2000 / 2003 | 11 | 17th November 2011 03:10 |
| windows 2008 sp2 terminal services application issue | pledesma72 | Terminal Services | 4 | 7th December 2009 03:50 |
| Terminal Services 2003 - Application Server Mode | Vlad Tomsa | Terminal Services | 10 | 19th December 2008 14:53 |
| Terminal Services Application Analyzer Beta | yuval14 | Terminal Services | 0 | 12th July 2008 21:54 |