fixed typo in comments

This commit is contained in:
Marius Pana 2014-12-23 17:58:40 +02:00
parent 6a59ad33f7
commit 4469b45f64
1 changed files with 4 additions and 4 deletions

View File

@ -3,7 +3,7 @@
##################################################################################### #####################################################################################
# Exchange 2010 : per user mailbox size # Exchange 2010 : per user mailbox size
# Author: Marius Pana # Author: Marius Pana
# Company: Spearhead Systems # Company: Spearhead Systems
# Date 12/16/14 # Date 12/16/14
##################################################################################### #####################################################################################
@ -16,7 +16,7 @@ add-PSSnapin Microsoft.Exchange.Management.PowerShell.E2010
# PrimarySmtpAddress = $mailbox.PrimarySmtpAddress # PrimarySmtpAddress = $mailbox.PrimarySmtpAddress
# TotalItemSize = $Stat.TotalItemSize.value.ToMB() # TotalItemSize = $Stat.TotalItemSize.value.ToMB()
# } # }
#}) | Select PrimarySmtpAddress,TotalItemSize | #}) | Select PrimarySmtpAddress,TotalItemSize |
#Export-CSV C:\CMK-MailboxReport.csv -NTI} #Export-CSV C:\CMK-MailboxReport.csv -NTI}
# filename for timestamp # filename for timestamp
@ -36,7 +36,7 @@ If (Test-Path $timestamp){
$filedate = (ls $timestamp).LastWriteTime $filedate = (ls $timestamp).LastWriteTime
$now = Get-Date $now = Get-Date
$earlier = $now.AddSeconds(-$delay) $earlier = $now.AddSeconds(-$delay)
# exit if timestamp to young # exit if timestamp too young
if ( $filedate -gt $earlier ) { exit } if ( $filedate -gt $earlier ) { exit }
} }
# create new timestamp file # create new timestamp file
@ -51,7 +51,7 @@ $Stat = $mailbox | Get-MailboxStatistics | Select TotalItemSize
PrimarySmtpAddress = $mailbox.PrimarySmtpAddress PrimarySmtpAddress = $mailbox.PrimarySmtpAddress
TotalItemSize = $Stat.TotalItemSize.value.ToMB() TotalItemSize = $Stat.TotalItemSize.value.ToMB()
} }
}) | Select PrimarySmtpAddress,TotalItemSize | }) | Select PrimarySmtpAddress,TotalItemSize |
Export-CSV C:\CMK-MailboxReport.csv -NoTypeInformation Export-CSV C:\CMK-MailboxReport.csv -NoTypeInformation
(Get-Content C:\CMK-MailboxReport.csv) | Foreach-Object {$_ -replace '"', ''} | Foreach-Object {$_ -replace ',', ' '} | select -Skip 1 | Set-Content C:\CMK-MailboxReport.csv (Get-Content C:\CMK-MailboxReport.csv) | Foreach-Object {$_ -replace '"', ''} | Foreach-Object {$_ -replace ',', ' '} | select -Skip 1 | Set-Content C:\CMK-MailboxReport.csv