PowerShell ActiveSync report about all users Exchange 2010

teggra
teggra used Ask the Experts™
on
Dear all,

I have a goal:
- PowerShell Script
- HTML report
- Report about all users in the domain which are using a mobile device
--- Inside the report, I want to have the following attributes:
----- DeviceFriendlyName, Devicetype, DeviceUserAgent, lastsuccesssync, Username
----- in the export i want to have friendly device user agent names, means with a convert table

I think the report is not complicated - but can't get it running.
I can epxort easily the following attributes 'DeviceFriendlyName, Devicetype, DeviceUserAgent, lastsuccesssync',
but how I can add the mailbox? I don't want to use the identity - it's not user friendly.



Get-Mailbox | ForEach {Get-ActiveSyncDeviceStatistics -Mailbox:$_.Identity} | ft DeviceFriendlyName, Devicetype, DeviceUserAgent, identity


Thanks for the hints.
regards
teggra
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
teggraSystem Engineer

Author

Commented:
e.g. I can use the following script;

how I can export in HTML at the end?
http://pastebin.com/GfV1e4CW


-> $deviceinfo | ConvertTo-HTML | Out-File C:\Scripts\Test.htm  ?

Microsoft Systems Admin
Commented:
add the following:

ConvertTo-HTML | Out-File C:\Scripts\Test.htm


see examples here

http://technet.microsoft.com/en-us/library/ff730936.aspx
teggraSystem Engineer

Author

Commented:
Used for my report.
Thanks

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial