Title:
MCAD / MCSD self-paced training kit developing windows-based applications with microsoft visual basic .NET and microsoft visual C# .NET
Publication Information:
Redmond, Washington : Microsoft Press, 2002
ISBN:
9780735615335
Available:*
Library | Item Barcode | Call Number | Material Type | Item Category 1 | Status |
---|---|---|---|---|---|
Searching... | 30000003605650 | QA76.3 M33 2002 | Open Access Book | Book | Searching... |
On Order
Summary
Summary
Key Book Benefits: - NEW--Delivers revised and expanded content for developing Windows-based applications with the .NET Framework. - NEW--Features enhanced testing tool that generates realistic practice exams with automated scoring and detailed explanations for right and wrong answers. - Thoroughly covers the objectives for two MCP Exams--70-306 and 70-316--core requirements on the MCAD/MCSD tracks - Provides side-by-side code examples and labs for both Visual Basic .NET and Visual C# .NET - Includes 60-day evaluation version of Microsoft Visual Studio(R) .NET Professional Edition on DVD
Table of Contents
About This Book | p. xiii |
Chapter 1 Introduction to the .NET Framework | p. 1 |
About This Chapter | p. 1 |
Before You Begin | p. 1 |
Lesson 1 The .NET Framework and the Common Language Runtime | p. 2 |
Overview of the .NET Framework | p. 2 |
Languages and the .NET Framework | p. 2 |
The Structure of a .NET Application | p. 3 |
Compilation and Execution of a .NET Application | p. 4 |
Lesson 2 The .NET Base Class Library | p. 6 |
Reference Types and Value Types | p. 8 |
Using .NET Framework Types in Your Application | p. 9 |
The Imports and using Statements | p. 12 |
Referencing External Libraries | p. 13 |
Lesson 3 Using Classes and Structures | p. 15 |
Members | p. 15 |
Creating Classes | p. 16 |
Creating Structures | p. 16 |
Adding Members | p. 16 |
Nested Types | p. 17 |
Instantiating User-Defined Types | p. 18 |
Classes vs. Structures | p. 19 |
Lesson 4 Using Methods | p. 20 |
Adding Methods | p. 20 |
Calling Methods | p. 21 |
Method Variables | p. 21 |
Parameters | p. 22 |
Constructors and Destructors | p. 25 |
Lesson 5 Scope and Access Levels | p. 28 |
Member Access Modifiers | p. 28 |
Type Access Modifiers | p. 30 |
Access Modifiers for Nested Types | p. 31 |
Shared (static) Members | p. 31 |
Lesson 6 Garbage Collection | p. 34 |
Circular References | p. 35 |
Lab 1 Classes and Garbage Collection | p. 37 |
Before You Begin | p. 37 |
Exercise 1.1 Making the Demo Class | p. 37 |
Exercise 1.2 Demonstrating Garbage Collection | p. 38 |
Review | p. 40 |
Chapter 2 Creating the User Interface | p. 41 |
About This Chapter | p. 41 |
Before You Begin | p. 41 |
Lesson 1 User Interface Design Principles | p. 42 |
Forms, Controls, and Menus | p. 42 |
Composition | p. 43 |
Lesson 2 Using Forms | p. 47 |
Adding Forms to Your Project | p. 47 |
Visual Inheritance | p. 48 |
Setting the Startup Form | p. 50 |
Setting the Startup Location | p. 51 |
Changing the Appearance of Your Form | p. 52 |
BackColor, ForeColor, and Text Properties | p. 53 |
Font, Cursor, and BackGroundImage | p. 53 |
Opacity | p. 53 |
Using Form Methods | p. 54 |
Show and ShowDialog | p. 55 |
Activate | p. 55 |
Hide | p. 56 |
Close | p. 56 |
Using Form Events | p. 56 |
Form Lifetime Events | p. 58 |
Lesson 3 Using Controls and Components | p. 62 |
Working with Controls | p. 62 |
Setting the Control Tab Order | p. 64 |
Controls That Can Contain Other Controls | p. 65 |
Docking and Anchoring Controls | p. 66 |
Using the Controls Collection | p. 69 |
Adding Controls to the Toolbox | p. 70 |
Creating Event Handlers for Controls | p. 71 |
Using Extender Provider Components | p. 72 |
Lesson 4 Using Menus | p. 75 |
Creating Menus at Design Time | p. 75 |
Using the MainMenu Component | p. 76 |
Separating Menu Items | p. 77 |
Menu Access and Shortcut Keys | p. 78 |
Using Menu Item Events | p. 79 |
Creating Context Menus | p. 79 |
Modifying Menus at Run Time | p. 80 |
Enabling and Disabling Menu Commands | p. 80 |
Displaying Check Marks on Menu Items | p. 80 |
Displaying Radio Buttons on Menu Items | p. 80 |
Making Menu Items Invisible | p. 81 |
Cloning Menus | p. 81 |
Merging Menus at Run Time | p. 82 |
Adding Menu Items at Run Time | p. 82 |
Lesson 5 Validating User Input | p. 84 |
Field-Level Validation | p. 84 |
Using Events in Field-Level Validation | p. 86 |
Handling the Focus | p. 88 |
Form-Level Validation | p. 90 |
Providing User Feedback | p. 92 |
Lab 2 The Virtual Doughnut Factory | p. 96 |
Before You Begin | p. 96 |
Exercise 2.1 Creating the User Interface | p. 96 |
Exercise 2.2 Adding a Menu | p. 100 |
Exercise 2.3 Creating Validation Handlers | p. 101 |
Review | p. 104 |
Chapter 3 Types and Members | p. 105 |
About This Chapter | p. 105 |
Before You Begin | p. 105 |
Lesson 1 Using Data Types | p. 106 |
The .NET Data Types | p. 106 |
Converting Types | p. 109 |
Using Data Type Functionality | p. 112 |
Lesson 2 Constants, Enums, Arrays, and Collections | p. 116 |
Constants and Enumerations | p. 116 |
Arrays | p. 120 |
Collections | p. 124 |
Enumerating the Members of an Array or Collection | p. 127 |
Lesson 3 Implementing Properties | p. 130 |
Implementing Properties | p. 130 |
Read-Only and Write-Only Properties | p. 133 |
Parameterized Properties | p. 134 |
Default Properties and Indexers | p. 135 |
Collection Properties | p. 136 |
Lesson 4 Implementing Delegates and Events | p. 140 |
Delegates | p. 140 |
Declaring and Raising Events | p. 142 |
Implementing Event Handlers | p. 143 |
Event Handlers That Handle Multiple Events | p. 145 |
Events with Multiple Handlers | p. 146 |
Removing Handlers at Run Time | p. 146 |
Lab 3 Adding Components and Implementing Members | p. 148 |
Before You Begin | p. 148 |
Exercise 3.1 Creating the DoughnutMachine Component | p. 148 |
Exercise 3.2 Adding the DoughnutMachine to the User Interface | p. 155 |
Review | p. 160 |
Chapter 4 Object-Oriented Programming and Polymorphism | p. 161 |
About This Chapter | p. 161 |
Before You Begin | p. 161 |
Lesson 1 Introduction to Object-Oriented Programming | p. 162 |
Objects, Members, and Abstraction | p. 162 |
Encapsulation | p. 164 |
Polymorphism | p. 164 |
Lesson 2 Overloading Members | p. 167 |
Creating Overloading Methods | p. 168 |
Overloading Operators with Visual C# | p. 169 |
Lesson 3 Interface Polymorphism | p. 172 |
Defining Interfaces | p. 172 |
Polymorphism with Interfaces | p. 174 |
Implementing Interfaces | p. 175 |
Lesson 4 Inheritance Polymorphism | p. 180 |
Inheritance | p. 180 |
Inherited Members | p. 182 |
Abstract Classes and Members | p. 189 |
Lab 4 Using Inherited Classes | p. 193 |
Before You Begin | p. 193 |
Exercise 4.1 Creating a Strongly Typed Collection Class by Extending CollectionBase | p. 193 |
Exercise 4.2 Implementing Additional Doughnut Types | p. 196 |
Exercise 4.3 Implementing the RemoveStale Method | p. 199 |
Review | p. 204 |
Chapter 5 Testing and Debugging Your Application | p. 205 |
About This Chapter | p. 205 |
Before You Begin | p. 205 |
Lesson 1 Using the Debugging Tools | p. 206 |
Types of Errors | p. 206 |
Break Mode | p. 208 |
Setting Breakpoints | p. 211 |
Using the Debugging Windows | p. 213 |
Lesson 2 Using the Debug and Trace Classes | p. 218 |
How Tracing Works | p. 218 |
Writing Trace and Debug Output | p. 219 |
The Listeners Collection | p. 221 |
Using Trace Switches | p. 223 |
Configuring Trace Switches | p. 226 |
Lesson 3 Creating a Unit Test Plan | p. 229 |
The Unit Test Plan | p. 229 |
Lesson 4 Handling and Throwing Exceptions | p. 234 |
How Exceptions Are Handled | p. 234 |
Creating an Exception Handler | p. 235 |
Throwing Exceptions | p. 239 |
Lab 5 Debugging an Application | p. 244 |
Before You Begin | p. 244 |
Exercise 5.1 Identifying Syntax Errors | p. 244 |
Review | p. 248 |
Chapter 6 Data Access Using ADO.NET | p. 249 |
About This Chapter | p. 249 |
Before You Begin | p. 249 |
Lesson 1 Overview of ADO.NET | p. 250 |
Disconnected Database Access | p. 250 |
ADO.NET Data Architecture | p. 251 |
Lesson 2 Accessing Data | p. 255 |
Connecting to a Database | p. 255 |
Using Data Commands | p. 258 |
Using DataReaders | p. 264 |
Creating and Configuring DataAdapters | p. 271 |
Retrieving Data Using DataAdapters | p. 273 |
Lesson 3 Using DataSet Objects and Updating Data | p. 280 |
Creating and Filling DataSet Objects Without a DataAdapter | p. 280 |
DataRelation Objects | p. 285 |
Constraints | p. 286 |
Editing and Updating Data | p. 289 |
Lesson 4 Binding, Viewing, and Filtering Data | p. 297 |
Data Binding | p. 297 |
Filtering and Sorting Data | p. 305 |
Lesson 5 Using XML in ADO.NET | p. 311 |
Retrieving XML from a SQL Server 2000 Database | p. 311 |
Using XML with DataSets | p. 312 |
Using the XmlDataDocument Class | p. 314 |
Lab 6 Connecting with a Database | p. 319 |
Before You Begin | p. 319 |
Exercise 6.1 Adding Data Access and Using the DataReader | p. 319 |
Exercise 6.2 Retrieving and Updating Data Using DataAdapter Objects and a DataSet | p. 321 |
Exercise 6.3 Creating a Typed DataSet Using the XML Designer | p. 323 |
Exercise 6.4 Using the Data Form Wizard | p. 325 |
Review | p. 328 |
Chapter 7 Creating Controls Using the .NET Framework | p. 329 |
About This Chapter | p. 329 |
Before You Begin | p. 329 |
Lesson 1 Using GDI+ | p. 330 |
The System.Drawing Namespaces | p. 330 |
The Graphics Object | p. 331 |
Colors, Brushes, and Pens | p. 335 |
Rendering Simple Shapes | p. 338 |
Rendering Text | p. 339 |
Rendering Complex Shapes | p. 340 |
Lesson 2 Authoring Controls | p. 344 |
Overview of Control Authoring | p. 344 |
Creating an Inherited Control | p. 347 |
Creating a User Control | p. 349 |
Creating a Custom Control | p. 352 |
Lesson 3 Common Tasks Using Controls | p. 355 |
Adding Your Control to the Toolbox | p. 355 |
Providing a Toolbox Bitmap for Your Control | p. 355 |
Debugging Your Control | p. 357 |
Managing Control Licensing | p. 358 |
Hosting Your Control in Internet Explorer | p. 360 |
Lab 7 Creating a Custom Control | p. 362 |
Before You Begin | p. 362 |
Exercise 7.1 Creating the Control | p. 362 |
Exercise 7.2 Testing Your Control | p. 367 |
Review | p. 369 |
Chapter 8 Advanced .NET Framework Topics | p. 371 |
About This Chapter | p. 371 |
Before You Begin | p. 371 |
Lesson 1 Implementing Print Functionality | p. 372 |
The PrintDocument Component | p. 372 |
Printing Content | p. 375 |
Using PrintPreviewControl | p. 381 |
Configuring Printing | p. 382 |
Lesson 2 Accessing and Invoking Components | p. 386 |
Accessing .NET and COM Type Libraries | p. 386 |
Instantiating ActiveX Controls | p. 388 |
Accessing a Web Service | p. 388 |
Accessing the Windows API | p. 392 |
Lesson 3 Implementing Accessibility | p. 395 |
Accessibility Design | p. 395 |
Accessibility and the Certified for Windows Program | p. 396 |
Accessibility Properties of Windows Forms Controls | p. 397 |
Lesson 4 Implementing Help in Your Application | p. 399 |
The Help Class | p. 399 |
The HelpProvider Component | p. 400 |
Lesson 5 Globalization and Localization | p. 402 |
Globalization and Localization | p. 402 |
Culture-Specific Formatting | p. 407 |
Lab 8 Creating a Localized Form with Print Support | p. 413 |
Before You Begin | p. 413 |
Exercise 8.1 Creating the Form | p. 413 |
Exercise 8.2 Localizing the Form | p. 416 |
Exercise 8.3 Adding Print Support | p. 419 |
Review | p. 422 |
Chapter 9 Assemblies, Configuration, and Security | p. 423 |
About This Chapter | p. 423 |
Before You Begin | p. 423 |
Lesson 1 Assemblies and Resources | p. 424 |
Assemblies | p. 424 |
Resources and Resource Assemblies | p. 427 |
Shared Assemblies | p. 433 |
Lesson 2 Configuring and Optimizing Your Application | p. 437 |
Creating the Configuration File | p. 437 |
Configuring Your Application Using Dynamic Properties | p. 439 |
Optimizing Your Application's Performance | p. 443 |
Lesson 3 Securing Your Application | p. 446 |
Permissions | p. 447 |
Configuring Role-Based Authorization | p. 447 |
Configuring Code Access Security | p. 452 |
Using Exception Handling with Imperative Security | p. 459 |
Lab 9 Configuring and Securing an Application | p. 461 |
Before You Begin | p. 461 |
Exercise 9.1 Adding the Configuration File | p. 461 |
Exercise 9.2 Securing Your Application | p. 463 |
Review | p. 466 |
Chapter 10 Deploying Your Application | p. 467 |
About This Chapter | p. 467 |
Before You Begin | p. 467 |
Lesson 1 Planning the Deployment of Your Project | p. 468 |
XCOPY Deployment | p. 468 |
Creating Setup Projects | p. 469 |
Configuring Build Properties of Your Setup Project | p. 473 |
Building, Distributing, and Deploying a Setup Project | p. 477 |
Lesson 2 Configuring Your Setup Project | p. 481 |
Setting the Setup Project Properties | p. 481 |
The Installation Editors | p. 483 |
Installing a Native Assembly Image | p. 495 |
Verifying Installed Assembly Security Policies | p. 496 |
Lab 10 Creating an Installer Application | p. 498 |
Before You Begin | p. 498 |
Exercise 10.1 Creating the Setup Project | p. 498 |
Exercise 10.2 Configuring Your Application | p. 499 |
Exercise 10.3 Installing Your Application | p. 499 |
Review | p. 501 |
Appendix A Questions and Answers | p. 503 |
Glossary | p. 515 |
Index | p. 523 |