Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

i have two textboxes one for user name and another for
password . i have a table name compare(which contains
name,passwod etc.,)my doubt is how compare username
textbox with name column and how compare password textbox
with passwod column. i want the code

Answer Posted / vijay

sqldatasource s=new sqldatasource();
s.connectionstring=configurationmanager.connectionstring
["compareconnectionstring"].connectionstring;
s.selectcommand="select count(*) from compare where uid='"
+ textbox1.text + "'and pwd='" + textbox2.text + "'";
Dataview dv=new dataview();
dv=(dataview)s.select(datasourceselectarguments.empty)
if(dv[0][0]>0){} //found
else{}//not found

Is This Answer Correct ?    0 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Command objects uses, purposes and their methods.

927


What are the major difference between classic ADO and ADO.NET?

938


Which is faster ado.net or linq?

953


How do you connect to sql server database without using sqlclient?

1039


Why do we serialize data?

884


Does executenonquery return a value?

883


What are the Features and disadvantages of dataset

1034


Explain the DataAdapter.Update() and DataSetAcceptChanges() methods.

946


What are the data access namespaces in .NET?

1131


What are the different ado.net namespaces are available in .net?

941


Is entity framework better than ado.net?

928


How do you find the count of records in a dataset?

909


Explain the advantages and disadvantages of using datalist?

1026


What is Data view?

1005


What is acid in ado.net?

948