Checking User Name and Password for .net application

For the net application we can use the login with simple logic.

Dont check with given user name and password with hole database. By using Execute Scalar we return '1' if the given login details are correct. if it is return '0' then we assume login details are incorrect.

I think this will helpful for the freshers.

Thanks


Comments

Author: Prakash kumar pothal18 Feb 2010 Member Level: Gold   Points : 2

Checking User Name and Password for .net application is very simple.

First u create a class for Authentic the username and password.
From ur page u pass this two parameters (Username/Password).
than in ur class u can write s query for get all the username and password than mathched with ur parameters.if it is match than return true or 1 else false or 0.

On the basic of this return value u diplay the message in ur page.



Regards,
prakash



  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:
    Email: