Generate a random password in .Net C#

Edit
I was asking "how to generate a random password" and then I found out there is a handy method provided by microsoft that can do the trick! It is under the System.Web package

you can specify the length of the password and the number of non alphanumeric characters. It is very useful when you need to generate a temporary password to give to your user in case like, forget password or reset password.

The official doc is in Membership.GeneratePassword Method (System.Web.Security)

Generate a random password in .Net C# Generate a random password in .Net C# Reviewed by DF on 5:57:00 PM Rating: 5
©DF. Powered by Blogger.