The thing to remember is that everything in PowerShell is an object. When you use Format-Table, the output is a formatting object and that's what is getting passed in to export CSV. If you pipe the results of the Format-Table command to Get-Member, you'll see what I mean.
Get-ActiveSyncDevice |
Get-ActiveSyncDeviceStatistics |
sort-object status, devicetype , lastsyncattempttime |
Format-Table FirstSyncTime ,LastPolicyUpdateTime ,LastSyncAttemptTime ,LastSuccessSync , DeviceType , DeviceID, DeviceAccessState, Identity -a |
Get-Member
The output of that will be a series of descriptions of various formatting objects.
Format-Table is great for creating output in your console session or sending formatted output to a text file (using out-file), but if we change your Format-Table to Select-Object, your CSV file will be more of what you expect.
Get-ActiveSyncDevice |
Get-ActiveSyncDeviceStatistics |
sort-object status, devicetype , lastsyncattempttime |
select FirstSyncTime ,LastPolicyUpdateTime ,LastSyncAttemptTime ,LastSuccessSync , DeviceType , DeviceID, DeviceAccessState, Identity |
Export-Csv c:\activesync.csv
(Side note.. for long pipelines the pipe character can be used as a line continuation.)