• Microsoft庐 Visual C#庐 2005 Step by Step
  • Copyright
    • Companion Content
  • Introduction
    • Finding Your Best Starting Point in This Book
    • Conventions and Features in This Book
    • Online Companion Content
    • System Requirements
    • Installing and Using the Practice Files
    • Support for this Book
  • Part I: Introducing Microsoft Visual C# and Microsoft Visual Studio 2005
    • Chapter 1: Welcome to C#
      • Beginning Programming with the Visual Studio 2005 Environment
      • Writing Your First Program
      • Using Namespaces
      • Creating a Windows Forms Application
      • Chapter 1 Quick Reference
    • Chapter 2: Working with Variables, Operators, and Expressions
      • Understanding Statements
      • Using Identifiers
      • Identifying Keywords
      • Using Variables
      • Working with Primitive Data Types
      • Using Arithmetic Operators
      • Incrementing and Decrementing Variables
      • Chapter 2 Quick Reference
    • Chapter 3: Writing Methods and Applying Scope
      • Declaring Methods
      • Calling Methods
      • Applying Scope
      • Writing Methods
      • Chapter 3 Quick Reference
    • Chapter 4: Using Decision Statements
      • Declaring bool Variables
      • Using Boolean Operators
      • Using if Statements to Make Decisions
      • Using switch Statements
      • Chapter 4 Quick Reference
    • Chapter 5: Using Compound Assignment and Iteration Statements
      • Using Compound Assignment Operators
      • Writing while Statements
      • Writing for Statements
      • Writing do Statements
      • Chapter 5 Quick Reference
    • Chapter 6: Managing Errors and Exceptions
      • Coping with Errors
      • Trying Code and Catching Exceptions
      • Using Checked and Unchecked Integer Arithmetic
      • Throwing Exceptions
      • Using a finally Block
      • Chapter 6 Quick Reference
    • Part II: Understanding the C# Language
      • Chapter 7: Creating and Managing Classes and Objects
        • Understanding Classification
        • The Purpose of Encapsulation
        • Defining and Using a Class
        • Controlling Accessibility
        • Working with Constructors
        • Understanding static Methods and Data
        • Chapter 7 Quick Reference
      • Chapter 8: Understanding Values and References
        • Copying int Variables and Classes
        • Using ref and out Parameters
        • How Computer Memory is Organized
        • The System.Object Class
        • Boxing
        • Unboxing
        • Chapter 8 Quick Reference
      • Chapter 9: Creating Value Types with Enumerations and Structs
        • Working with Enumerations
        • Working with Structure Types
        • Chapter 9 Quick Reference
      • Chapter 10: Using Arrays and Collections
        • What Is an Array?
        • What Are Collection Classes?
        • Chapter 10 Quick Reference
      • Chapter 11: Understanding Parameter Arrays
        • Using Array Arguments
        • Chapter 11 Quick Reference
      • Chapter 12: Working with Inheritance
        • What Is Inheritance?
        • Using Inheritance
        • Creating Interfaces
        • Abstract Classes
        • Sealed Classes
        • Extending an Inheritance Hierarchy
        • Summarizing Keyword Combinations
        • Chapter 12 Quick Reference
      • Chapter 13: Using Garbage Collection and Resource Management
        • The Life and Times of an Object
        • Resource Management
        • Making Code Exception-Safe
        • Chapter 13 Quick Reference
      • Part III: Creating Components
        • Chapter 14: Implementing Properties to Access Attributes
          • Comparing Fields and Methods
          • What Are Properties?
          • Understanding the Property Restrictions
          • Declaring Interface Properties
          • Chapter 14 Quick Reference
        • Chapter 15: Using Indexers
          • What Is an Indexer?
          • Indexers in Interfaces
          • Using Indexers in a Windows Application
          • Chapter 15 Quick Reference
        • Chapter 16: Delegates and Events
          • Declaring and Using Delegates
          • The Automated Factory Scenario
          • Using Delegates
          • Anonymous Methods and Delegates
          • Enabling Notifications with Events
          • Declaring an Event
          • Subscribing to an Event
          • Unsubscribing from an Event
          • Raising an Event
          • Understanding GUI Events
          • Using Events
          • Chapter 16 Quick Reference
        • Chapter 17: Introducing Generics
          • The Problem with Objects
          • The Generics Solution
          • Creating a Generic Class
          • Creating a Generic Method
          • Chapter 17 Quick Reference
        • Chapter 18: Enumerating Collections
          • Enumerating the Elements in Collection
          • Implementing an Enumerator by Using an Iterator
          • Chapter 18 Quick Reference
        • Chapter 19: Operator Overloading
          • Understanding Operators
          • Understanding Compound Assignment
          • Declaring Increment and Decrement Operators
          • Defining Operator Pairs
          • Implementing an Operator
          • Understanding Conversion Operators
          • Chapter 19 Quick Reference
        • Part IV: Working with Windows Applications
          • Chapter 20: Introducing Windows Forms
            • Creating Your Application
            • Adding Controls to the Form
            • Publishing Events in Windows Forms
            • Run the Application
            • Chapter 20 Quick Reference
          • Chapter 21: Working with Menus and Dialog Boxes
            • Menu Guidelines and Style
            • Adding Menus and Processing Menu Events
            • Pop-Up Menus
            • Using Common Dialog Controls
            • Chapter 21 Quick Reference
          • Chapter 22: Performing Validation
            • Validating Data
            • An Example鈥擟ustomer Maintenance
            • Chapter 22 Quick Reference
          • Part V: Managing Data
            • Chapter 23: Using a Database
              • Using ADO.NET Databases
              • Using ADO.NET Programmatically
              • Chapter 23 Quick Reference
            • Chapter 24: Working with Data Binding and DataSets
              • Windows Forms Controls and Data Binding
              • Updating a Database Using a DataSet
              • Chapter 24 Quick Reference
            • Part VI: Building Web Applications
              • Chapter 25: Introducing ASP.NET
                • Understanding the Internet as an Infrastructure
                • Creating Web Applications with ASP.NET
                • Chapter 25 Quick Reference
              • Chapter 26: Understanding Web Forms Validation Controls
                • Comparing Server and Client Validations
                • Chapter 26 Quick Reference
              • Chapter 27: Securing a Web Site and Accessing Data with Web Forms
                • Using the Web Forms GridView Control
                • Managing Security
                • Querying Data
                • Editing Data
                • Chapter 27 Quick Reference
              • Chapter 28: Creating and Using a Web Service
                • What Is a Web Service?
                • Building the ProductService Web Service
                • Web Services, Clients, and Proxies
                • Chapter 28 Quick Reference
              • About the Author