check when password expires windows 10 code example
Example: how to know when your windows password will expire
1. Open Windows Command Prompt.
2. Type in the below command. Replace with your acutal username.
net user /DOMAIN | findstr expires