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
How would you connect to a database by using .NET?
What are the Data providers in ADO.Net?
How many major types of connection objects in ADO.NET?
Which ado.net object is very fast in getting data from the database?
What is connected architecture in ado.net?
What are the methods of XML dataset object?
Why is stored procedure used in ado.net?
How to add a check box or a dropdown list to a column in a datagrid?
What is DataRowCollection?
How to pass multiple tables in datasets simultaneously?
Which object is used to add relationship between two Datatables?
What is the use of SqlCommandBuilder?
What is the default provider in ado.net?
Does entity framework use ado.net?
What is a string variable?