Did you type it exactly as Satcomer posted it?
Code:
dscl . -passwd /Users/<username> <password>
Where
<username> is your username and
<password> is the password you want to give the account. (Don't include the brackets when typing the username and password you're trying to change.)
Alsol, make sure you adhere to the lettercase given in the commands. Unix is case-sensitive.