Skip to content

Get-Mattifestation is broken #2

@jaredhaight

Description

@jaredhaight

I'm trying to figure out what my mattifestation count is, but the script is broken. Error out put is below, I took the try catch out to get the actual error.

PS C:\Users\Jared\Desktop> Get-Mattifestation -Handle jaredhaight
Cannot convert value "," to type "System.Int32". Error: "Input string was not in a correct format."
At C:\Users\Jared\Desktop\Get-Mattifestation.ps1:34 char:17
+                 [int]$Mattifestation = $Matches[1]
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [], RuntimeException
    + FullyQualifiedErrorId : InvalidCastFromStringToInteger

Cannot convert value "," to type "System.Int32". Error: "Input string was not in a correct format."
At C:\Users\Jared\Desktop\Get-Mattifestation.ps1:40 char:13
+             [int]$User = $Matches[1]
+             ~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (:) [], RuntimeException
    + FullyQualifiedErrorId : InvalidCastFromStringToInteger

Attempted to divide by zero.
At C:\Users\Jared\Desktop\Get-Mattifestation.ps1:43 char:9
+         $Properties = @{
+         ~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], RuntimeException
    + FullyQualifiedErrorId : RuntimeException

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions