Hi,
I use "Run program in guest" workflow in order to run the flowing commands:
& {net user /add taskadmin Aa123456 ; net localgroup administrators taskadmin /add ; Get-WmiObject win32_useraccount -filter 'name="taskadmin"' | Set-WmiInstance -Arguments @{passwordexpires=$false}}
The arguments variable which pass to "Run program in guest" workflow:
arguments = "-command \"& {net user /add taskadmin Aa123456 ; net localgroup administrators taskadmin /add ; Get-WmiObject win32_useraccount -filter 'name=\"taskadmin\"' | Set-WmiInstance -Arguments @{passwordexpires=$false}}\""
The user is created in administrators group but the password never expires in not checked.
What can be the solution for this issue?