1
Answer

What is ASP.NET?

Photo of Rinki

Rinki

Nov 14
47
1
What is ASP.NET?

Answers (1)

1
Photo of Hirendra Sisodiya
NA 8.8k 3m 14y
hello adam


try this

OleDbConnection oCon = new OleDbConnection("Put your Connection string");
            oCon.Open();
            object obj;

            string str = "Select count(*) from tablename where Login='" + UserId + "' ams password ='" + password + "' ";
            OleDbCommand cmd = new OleDbCommand(str, oCon);
            obj = cmd.ExecuteScalar();
            if ((int)obj!= 0)
            {
                //Login successfull
            }
            else
            {
                // Unsuccessfull
            }

thanks



please mark as answer if it helps

Accepted
Next Recommended Forum