If its any OS below Windows NT, 2000, or XP, you should be able to just ESC out.
Otherwise, check this out:
http://home.eunet.no/~pnordahl/ntpasswd/
NOTE: I can not vouch for the safety of the above program. It may fix your problem, but read the docs carefully.
www.sysinternals.com also has a pwd program,but I believe it is commercial.