Link to home
Start Free TrialLog in
Avatar of Bart Opiola
Bart OpiolaFlag for United States of America

asked on

Why is Set-Clutter import CSV erroring out?

PS Import-CSV –Path E:\PowerShellScripts\CSVTemplates\Template-ClutterFalse.csv| ForEach-Object { Set-Clutter -UserPrincipalName $_.UserPrincipalName -Enable $_.Enable }

Cannot process argument transformation on parameter 'Enable'. Cannot convert value "System.String" to type "System.Nullable`1[System.Boolean]". Boolean parameters accept only Boolean values and numbers, such as
$True, $False, 1 or 0.
    + CategoryInfo          : InvalidData: (:) [Set-Clutter], ParameterBindin...mationException
    + FullyQualifiedErrorId : ParameterArgumentTransformationError,Set-Clutter
    + PSComputerName        : outlook.office365.com
Avatar of Bart Opiola
Bart Opiola
Flag of United States of America image

ASKER

the CSV file has two columns: UserPrincipalName and Enable which are set to "email@domain.com" and "False" to turn clutter off
ASKER CERTIFIED SOLUTION
Avatar of oBdA
oBdA

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
This works better - thanks!