I'm getting a Powershell error like this:
PS C:\mydirectory> $Error[0]
Get-WmiObject :
At line:143 char:13
+ $Disk = Get-WmiObject MSCluster_Disk -ComputerName $Resource.OwnerNode -Auth ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [Get-WmiObject], COMException
+ FullyQualifiedErrorId : GetWMICOMException,Microsoft.PowerShell.Commands.GetWmiObjectCommand
Is there a way I can avoid the command that triggered the error (i.e., $Disk = Get-WmiObject MSCluster_Disk ...
) being truncated in the error message?