Hi ks ravi.
You will need to get a couple of things in order.
You need:
a) a connection
b) a way to query the database
c) a way to encapsulate and evaluate the results
First, you need to make the application you're developing aware of the database. The configuration is expressed as a connection string, which is often constructed and stored for you through the VS tools.
The easiest way to do what you're looking for might be to use LINQ to SQL. This is very well documented. The steps are along the lines of:
1) Use the server window to add a data connection to the database in question
2) Add a LINQ to SQL file to the database
3) Drag a table from the server explorer onto the LINQ to SQL designer
4) Compile your application
At this point, your application is fully aware of the database and the connection bits are constructed and ready to use. The configuration is stored in your app.config file. The result of the designer is a DataContext and its related classes.
Now, in your code, you're going to need to do the following:
1) Create an instance of the datacontext
2) "Ask" if your table contains the data
It might look something like this:
DesignerNameDataContext dc = new DesignerNameDataContext();
var matchingRecord = dc.table1.Where(c => c.column1 == txtbx.Text).FirstOrDefault();
if(matchingRecord == null)
{
}
I've given you a bunch of tools and vocabulary here. A Google search will get you further along the way. If you have any specific questions or need help with a particular concept, please post another question!
Hope this helps.
Cheers.