This series of articles is about ASP.NET. They are from my previous years, legacy notes on OneNote. Reviewing the concepts may be helpful even for our current programming because they have a lot of similar features, such as Angular, React, and these modern "laguanges".

A. Introduction

This article will be an ASP.NET Control Summary. I will just follow the exiting note without editing. It is quite informative.

B. ASP.NET Controls

  1. Validation controls: (ASP.NET 3.5, p144)
    1. RequiredFieldValidator,
    2. RangeValidator,
    3. CompareValidator,
    4. RegularExpressionValidator,
    5. CustomValidator,
    6. ValidationSummary
  2. Send Code to Client Side
    • RegisterClientScriptBlock: emits just after the opening tag of the Page object's
    • RegisterStartupScript: emits just before the closing tag of the Page object
  3. ADO.NET
    • SqlConnection class
    • SqlCommand class (SqpParameter class)
    • SqlCommandBuilder class
    • SqlDataReader class
    • SqlDataAdapter class
    • SqlTransaction class
    • Note. Using Data Designer could build a Typed reference to an object from the database
    • DataSet: Read/Write; multiple tables from different databases; Disconnected;
      • Forward/backward; slower access; supported by VS.NET tools; Bind to multiple controls
      • DataView: Represents a databindable, customized view of a DataTable for sorting, filtering, searching, editing, and navigation.
      • DataRelation: Represents a parent/child relationship between two
        • DataTable objects
        • DeleteRule of ForeignKeyConstrint:
          • Cascade (default), None, SetDefault, SetNull
      • DataTable: Represents one table of in-memory data.
      • DataRow: Represents a row of data in a DataTable.
    • DataReader: Read-only; based on SQL from one database; Connected; Forward Only; faster access; manually coded; Bind to one control
  4. ADO Objects
    • Connection, Errors - Error
    • Command, Parameters – Parameter
    • Recordset
      • CurserType:
        • ForwardOnly,
        • Static,
        • KeySet,
        • Dynamic
      • LockType:
        • ReadOnly,
        • Pessimistic (lock upon editing),
        • Optimistic (lock upon updating),
        • BatchOptimistic
  5. get a DataSet
    • Create a Connection
    • Create a DataAdapter
    • Create a DataSet
      • (Create a DataView for sorting, filtering, searching, editing, and navigation)
    • Bind both the DataSet and DataView to DataGrid controls
  6. Use a DataReader
    • Create a Connection
    • Create a Command
    • Create a DataReader from the Command by Call ExecuteReader method
    • Call Read for each record …
  7. List-bound controls
    • DropDownList
    • ListBox
    • Table
    • DataGrid
    • DataList
    • Repeater: the simplest List Bond control to support templet

C. ASP.NET Controls Features