Click here to Skip to main content
15,918,049 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Redirect to page below one level ...read the post completely ... Pin
eyeseetee29-Apr-08 22:52
eyeseetee29-Apr-08 22:52 
QuestionQuestion Pin
nithydurai29-Apr-08 21:28
nithydurai29-Apr-08 21:28 
AnswerRe: Duplicate Question Pin
eyeseetee29-Apr-08 21:43
eyeseetee29-Apr-08 21:43 
GeneralRe: Duplicate Question Pin
J4amieC29-Apr-08 22:13
J4amieC29-Apr-08 22:13 
GeneralRe: Duplicate Question Pin
eyeseetee29-Apr-08 22:30
eyeseetee29-Apr-08 22:30 
QuestionQuestion Pin
nithydurai29-Apr-08 21:25
nithydurai29-Apr-08 21:25 
AnswerRe: Question Pin
eyeseetee29-Apr-08 21:43
eyeseetee29-Apr-08 21:43 
QuestionLogin Control Message Pin
Member 387988129-Apr-08 19:39
Member 387988129-Apr-08 19:39 
Hi i am new for vs2005,
I have used login control in my Home.aspx page

With ref some site, i used the code,
But for me after login its not redirecting to next page.
Getting "Your login attempt was not successful. Please try again." Messgae only,
But my uid and pwd both are correct whats the probs?

This is my code:
protected void Login1_Authenticate(object sender, AuthenticateEventArgs e)
{
bool Authenticated = false;
Authenticated=SiteLevelCustomAuthenticationMethod(Login1.UserName,Login1.Password);
e.Authenticated = Authenticated;
if (Authenticated == true)
{ Response.Redirect("Sam.aspx"); }
}
private bool SiteLevelCustomAuthenticationMethod(String UserName, String Password)
{
bool boolReturnValue = false;
String strConnection = "Server=(local);database=WorkOut;uid=sa;pwd=bumi;";
SqlConnection Connection = new SqlConnection(strConnection);
String strSql = "Select * From UserLogin";
SqlCommand SqlCmd = new SqlCommand(strSql, Connection);
SqlDataReader SqlRd;
Connection.Open();
SqlRd = SqlCmd.ExecuteReader();
while (SqlRd.Read())
{
if((UserName == SqlRd["Name"].ToString())&(Password == SqlRd["Password"].ToString()))
{
boolReturnValue=true;
break;
}
}
SqlRd.Close();
return boolReturnValue;
}

Thanks & Regards,
NeW OnE,
please don't forget to vote on the post

QuestionRe: Login Control Message Pin
Abhijit Jana29-Apr-08 20:00
professionalAbhijit Jana29-Apr-08 20:00 
AnswerRe: Login Control Message Pin
Member 387988129-Apr-08 20:12
Member 387988129-Apr-08 20:12 
GeneralRe: Login Control Message Pin
N a v a n e e t h29-Apr-08 20:26
N a v a n e e t h29-Apr-08 20:26 
GeneralRe: Login Control Message Pin
Member 387988129-Apr-08 20:32
Member 387988129-Apr-08 20:32 
GeneralRe: Login Control Message Pin
Christian Graus29-Apr-08 21:22
protectorChristian Graus29-Apr-08 21:22 
GeneralRe: Login Control Message Pin
Abhijit Jana29-Apr-08 21:00
professionalAbhijit Jana29-Apr-08 21:00 
AnswerRe: Login Control Message Pin
eyeseetee29-Apr-08 21:25
eyeseetee29-Apr-08 21:25 
GeneralRe: Login Control Message Pin
Member 387988129-Apr-08 21:49
Member 387988129-Apr-08 21:49 
QuestionSession Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Member 382422429-Apr-08 19:01
Member 382422429-Apr-08 19:01 
AnswerRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Abhijit Jana29-Apr-08 19:35
professionalAbhijit Jana29-Apr-08 19:35 
AnswerRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
_AK_29-Apr-08 19:44
_AK_29-Apr-08 19:44 
AnswerRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Christian Graus29-Apr-08 19:46
protectorChristian Graus29-Apr-08 19:46 
GeneralRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Member 382422430-Apr-08 0:05
Member 382422430-Apr-08 0:05 
GeneralRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Christian Graus30-Apr-08 1:52
protectorChristian Graus30-Apr-08 1:52 
AnswerRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Vasudevan Deepak Kumar29-Apr-08 22:30
Vasudevan Deepak Kumar29-Apr-08 22:30 
GeneralRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Member 382422430-Apr-08 0:04
Member 382422430-Apr-08 0:04 
GeneralRe: Session Variables is only working on the Same Page but its not transfering the value to another page in asp.net 2.0 Pin
Member 382422430-Apr-08 0:05
Member 382422430-Apr-08 0:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.