(if (it = “Setting=True”) then (“PasswordComplexityEnabled: True”) else (“PasswordComplexityEnabled: False”)) of ((selects(“setting from RSOP_SecuritySettingboolean WHERE keyname=‘PasswordComplexity’ and precedence=1”) of rsop computer wmis) as string) whose (it starts with “Setting=”)
WARNING: This can run very slowly so be careful… if you make this a property, you should set it to run very infrequently.