Powershell not escaping special characters for password

  Kiến thức lập trình

all, I am working on a script to bulk create local users which works fine except for the password creation portion. The script pulls the information from a csv, but when I test the account with the password I think it should be using, it fails. I sense it is due to the special characters not being parsed. Here is a sample password I have in the csv password column.
Passw0rdforSDSSc1entist$2024
I tried with single quotes ‘Passw0rdforSDSSc1entist$2024’ and double quotes “Passw0rdforSDSSc1entist$2024”, as well as putting the escape () before the $, Passw0rdforSDSSc1entist$2024 but still does not work.

LEAVE A COMMENT