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...

what is the main difference between c and c++?

Answer Posted / lalit

public int validateuser(string username, string passwd)
{
con.Close();
con.Open();
cmd = new SqlCommand("sp_VALIDATION",con);
rd = cmd.ExecuteReader();
bool b = rd.Read();
if (b == false)
{
if (FormsAuthentication .Authenticate
(username ,passwd ))

return 2; //For Administrator

else
return 0; //For Unauthorized
User

}
else

return 1; //For Normal User


}


***************************************************
protected void btnenter_Click(object sender, EventArgs e)
{
int tempvar= stdinfo.validateuser
(txtboxadminname.Text ,txtboxpassword.Text);

if (tempvar == 2)
Response.Redirect("Admin/AdminHomePage.aspx");

else
lblerrormsg.Text = ("You Are Not Authorized
Admin!");
lblerrormsg.Visible = true;
}

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do we use polymorphism in oops?

981


What do you mean by overloading?

1024


what type of question are asked in thoughtworks pair programming round ?

2143


What is the highest level of cohesion?

987


assume the program must insert 4 elements from the key board and then do the following programs.sequential search(search one of the elements),using insertion sort(sort the element) and using selection sort(sort the element).

2070


Why we use classes in oop?

976


What does <> mean pseudocode?

1111


INSTANCE FIELDS DECLARED private ARE ACCESSIBLE BY THE METHODS ONLY.CAN WE CHANGE THE private FIELD OF AN OBJECT IN A METHOD OF SOME OTHER OBJECT OF THE SAME CLASS?

2145


What are constructors in oop?

1081


when to use 'mutable' keyword and when to use 'const cast' in c++

2107


What is inheritance in oop?

981


IS IT NECESSARY TO INITIALIZE VARIABLE? WHAT IF THE INSTANCE VARIABLE IS DECLARED final ? IS IT NECESSARY TO INITIALIZE THE final VARIABLE AT THE TIME OF THEIR DECLARATION?

2020


What is polymorphism give a real life example?

970


What is a null tree?

1077


What is destructor give example?

1008