C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




string in c#


Posted Date: 21 Aug 2007      Total Responses: 2

Posted By: dharani kumar       Member Level: Bronze     Points: 2


hiiiiiiiii,
in 1 text box it should accept the names only which i had given in data base if we entered the other the message should display showing that data is not valid
i am doin in windows application
c # code




Responses

Author: Danasegarane.A    21 Aug 2007Member Level: DiamondRating:     Points: 2
Try to use a DropdownBox . And populate the users from the table in the DropdownBox.And for the user to select the user from the DropdownBox




Author: ChandraShekarThota    21 Aug 2007Member Level: DiamondRating:     Points: 2
object myConnection; object myCommand; object myReader; myConnection = new OleDbConnection("PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA Source='" + Server.MapPath(".") + "/veracity.mdb'; "); myCommand = new OleDbCommand("select * from tblusers where username='" + TextBox1.Text + "' and password='" + TextBox2.Text + "'", myConnection); myCommand.Connection.Open(); myReader = myCommand.ExecuteReader(); if (myReader.HasRows()) { myReader.Read(); Response.Write("success"); } else { Response.Write("ERROR : Record NOT FOUND."); } myCommand.Connection.Close();


Post Reply
You must Sign In to post a response.
Next : Regarding .Net Assembly
Previous : add two numbers in c#.net
Return to Discussion Forum
Post New Message
Category: .NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

internet fax

Contact Us    Privacy Policy    Terms Of Use