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 6730245
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:23:10+00:00 2026-05-26T10:23:10+00:00

Forgive my somewhat-lacking ASP.NET knowledge for this question :) Here’s the scenario: I’m playing

  • 0

Forgive my somewhat-lacking ASP.NET knowledge for this question 🙂

Here’s the scenario: I’m playing around in VS2010, I’ve created a new ASP.NET Web Application (under Visual C#, Web templates). Nothing special, just a basic web application. No fancy MVC stuff.

Included in the template-generated solution is a Login page; Account/Login.aspx. On that page, is a Login button; the HTML looks like this:

<p class="submitButton">
    <asp:Button ID="LoginButton"
                runat="server"
                CommandName="Login"
                Text="Log In"
                ValidationGroup="LoginUserValidationGroup"/>
</p>

Again, nothing fancy. Now, the code behind:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Account_Login : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        RegisterHyperLink.NavigateUrl = "Register.aspx?ReturnUrl=" + HttpUtility.UrlEncode(Request.QueryString["ReturnUrl"]);
    }
}

Even less fancy. And finally, from web.config:

    <authentication mode="Forms">
        <forms loginUrl="~/Account/Login.aspx" timeout="2880"/>
    </authentication>

So, here is what I can’t quite figure out: when I run the app, I can click the Login button, and the app does something – but where is the code for that something?

Coming from the WPF world (with some background in ASP.NET), my first instinct is to zero-in on CommandName – but a search for anything relating to “Login” turns up dry. My second instinct is to look at the code-behind, but again, it’s pretty sparse and I don’t see anything that looks like it has anything to do with a Login button being clicked.

So where does the “magic” behind this button happen? There has to be something; I feel like I’ve overlooked something that is sitting right in front of my eyes.

  • 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-26T10:23:11+00:00Added an answer on May 26, 2026 at 10:23 am

    If you’re referring to the Default Web Application (not the empty) that comes out of the box with Visual Studio, you’ll notice that login button is inside an <asp:Login> server control. That’s where the magic is happening. It interfaces with the ASP.NET Membership provider if you look in the web.config, you’ll see references to that.

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

Sidebar

Related Questions

Forgive me for a potentially silly question here, but in other programming languages (scripting
Forgive me if this question is too silly. I am making a webpage on
Forgive a newbie, I don't even know how to ask this question properly: I
Forgive my ignorance if this is 'a basic question'..... I have a method that
Forgive me for this noob question, but is there such a setting that sets
Forgive me if this question has already been asked and answered. Given a class
Forgive me if this question is stupid, however what is the point of the
Forgive me if this question is very vague Some time back i faced this
Forgive me if this is a newbie question: I've got a menu set to
Forgive me for such a basic question; this is (I suppose) more of an

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.