To Intro Notes

Directions for Creating an ASP.Net Project

 

  1. Invoke Visual Studio 2015.

  2. Create a new ASP.Net Project:
    Select FILE >> New >> Project.
    From the New Project Dialog, select Templates >> Visual C# >> Web >> Visual Studio 2012 >> ASP.Net Empty Web Application.
    Browse for the location of the project and set ClickCounter as the name of the application.
    Verify that the checkbox "Create directory for solution is checked." Click OK.

  3. Add new web page to project:
    Select PROJECT >> Add New Item...
    On the Add Net Item dialog, select >> Visual C# >> Web >> Web Form.
    Click the Add button. Notice that a new web page named WebPage1.aspx has been added to the project.

  4. Enter design mode:
    Select the Design button below the WebForm1.aspx code window.

  5. Obtain controls for form from textbox:
    Double click on the TextBox and Button controls in the Toolbox.

  6. Resize the controls:
    if desired.

  7. Initialize text in textbox:
    In the Properties Window for the TextBox object, change the Text Property to "0" (zero).

  8. Enter text for button:
    In the Properties Window for the Button object, change the Text Property to "Click Me" (zero).

  9. Edit code-behind file:
    Double click on the Button object to open the code-behind file WebForm1.aspx.cs and write the Click event handler for the button.

  10. Enter event handler code:
    In the body of the Button1_Click event handler, enter the following code:

  11. Run application:
    Click the Start Button (green triangle).