Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6388853
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T03:19:51+00:00 2026-05-25T03:19:51+00:00

I have a login page which works fine. I would like your help for

  • 0

I have a login page which works fine. I would like your help for how can i do the Logout. I send you the CustomerLogin.cs class whic I created. The login1 which i have is a call to my web service. Can anyone tell me what to do?

public partial class CustomerLogin : System.Web.UI.Page
{
    protected login1.login CustomerLog;

    public CustomerLogin()
    {
        Page.Init += new System.EventHandler(Page_Init);
    }

    private void Page_Load(object sender, System.EventArgs e)
    {
        if (Session["userId"] != null)
        {
            Server.Transfer("FirstPage.aspx");
        }

    }

    private void Page_Init(object sender, EventArgs e)
    {
        //
        // CODEGEN: This call is required by the ASP.NET Web Form Designer.
        //
        InitializeComponent();
    }

    #region Web Form Designer generated code
    /// <summary>
    /// Required method for Designer support - do not modify
    /// the contents of this method with the code editor.
    /// </summary>
    private void InitializeComponent()
    {
        this.submitCusLogin.Click += new System.EventHandler(this.submitCusLogin_Click);
        this.Load += new System.EventHandler(this.Page_Load);

    }
    #endregion

    private void submitCusLogin_Click(object sender, System.EventArgs e)
    {
        string customerEmail;
        string customerPassword;

        customerEmail = txtEmail.Text;
        customerPassword = txtPassword.Text;

        //Make a call to the Web Service Login
        CustomerLog = new login1.login();
        //Access the Web method Customer_Details
        string getId = CustomerLog.Customer_Details(customerEmail, customerPassword);
        //Return a value.Check the value of the variable resultId and
        //either grant the customer access or return an error message.
        if (getId == "-1")
        {
            loginLabel.Text = "Invalid Login please re-enter your password and email!";


        }
        else
        {
            loginLabel.Text = "Welcome";
            Session["userId"] = int.Parse(getId);
            Server.Transfer((string)Session["return2Page"]);
        }


    }

} 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T03:19:51+00:00Added an answer on May 25, 2026 at 3:19 am

    try to remove Session[“userId”] by using Session.Remove("userId") and redirect to log in page, i’m not sure on login method what you are doing. if you change login status on that method you need to reset that again on the log out method.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Scenario: I have a login page which uses ajax to validate a user and
I have a login page (an activity in Android), during which I run an
I have an ASP.Net website which has a remember me feature for Login page.
I have simple login box, which is centered to the middle of page (vertical
I have a login form, which needs to be re-directed to the main page
I have a child page LoginContent.aspx which contains a login form. If the user
I have a Login page that captures User input like this. MD5calc ss =
Using 960.gs, I have a page which is a login screen which uses a
i have used the login script which is found here http://www.phpeasystep.com/phptu/6.html the script works
I have a simple login page and the URL structure is like www.mydomain.com/admin/auth I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.