Sams teach yourself ASP.NET 4.0 in 24 hours: complete starter kit 9780672333057, 0672333058

Designed for beginners with experience in scripting and programming, this books introduces the main concepts in ASP.NET

553 57 21MB

English Pages xi, 630 pages: illustrations; 24 cm + 1 DVD-ROM [649] Year 2010

Report DMCA / Copyright

DOWNLOAD FILE

Sams teach yourself ASP.NET 4.0 in 24 hours: complete starter kit
 9780672333057, 0672333058

Table of contents :
Cover......Page 1
Table of Contents......Page 6
Introduction......Page 16
Part I: Getting Started with ASP.NET......Page 20
HOUR 1: Getting Started with ASP.NET......Page 22
What Is ASP.NET?......Page 23
Installing the .NET Framework, Visual Web Developer, and SQL Server 2008......Page 29
A Brief Tour of Visual Web Developer......Page 31
Q&A......Page 38
Workshop......Page 39
Examining the HTML Portion of an ASP.NET Page......Page 40
Examining the Source Code Portion of an ASP.NET Page......Page 59
Workshop......Page 68
HOUR 3: Using Visual Web Developer......Page 72
Creating a New Website......Page 73
Opening Existing Websites......Page 75
Working with Web Pages and Other Content......Page 76
Customizing the Visual Web Developer Experience......Page 80
Viewing, Moving, and Resizing Windows......Page 83
A World of Help at Your Fingertips......Page 84
Q&A......Page 85
Workshop......Page 86
Specifying the Design Requirements......Page 88
Creating the User Interface......Page 91
Writing the Source Code for the ASP.NET Page......Page 97
Testing the Financial Calculator......Page 101
Examining the Source Code......Page 107
Using the Debugger......Page 108
Q&A......Page 112
Workshop......Page 113
HOUR 5: Understanding Visual Basic’s Variables and Operators......Page 116
The Purpose of Programming Languages......Page 117
Declaring and Using Variables......Page 118
Examining Visual Basic’s Operators......Page 125
Learning Visual Basic’s Type Rules......Page 131
Workshop......Page 133
HOUR 6: Managing Program Flow with Visual Basic’s Control Structures......Page 136
Understanding Control Structures......Page 137
Exploring the Conditional Control Structure......Page 138
Working with Visual Basic’s Looping Control Structures......Page 143
Exploring the Modularizing Control Structures: Subroutines and Functions......Page 146
Q&A......Page 157
Workshop......Page 159
HOUR 7: Working with Objects in Visual Basic......Page 162
Reexamining the Role of Classes and Objects......Page 163
Creating an Object......Page 165
Setting an Object’s Properties......Page 166
Calling an Object’s Methods......Page 167
Creating Event Handlers for an Object’s Events......Page 168
Workshop......Page 170
Examining the Web Controls Designed for Displaying Text......Page 172
Using the Literal Web Control......Page 173
Using the Label Web Control......Page 178
Q&A......Page 187
Workshop......Page 188
Part II: Collecting and Processing User Input......Page 192
HOUR 9: Web Form Basics......Page 194
Gathering User Input in an HTML Web Page......Page 195
Dissecting ASP.NET Web Forms......Page 201
Q&A......Page 213
Workshop......Page 214
HOUR 10: Using Text Boxes to Collect Input......Page 216
Learning About the TextBox Web Control Basics......Page 217
Creating Multiline and Password Text Boxes......Page 220
Examining the TextBox Web Control’s Properties......Page 226
Q&A......Page 231
Workshop......Page 233
HOUR 11: Collecting Input Using Drop-Down Lists, Radio Buttons, and Check Boxes......Page 236
Examining the Different Types of User Input Classifications......Page 237
Examining the DropDownList Web Control......Page 239
Selecting One Option from a List of Suitable Choices with RadioButton Web Controls......Page 248
Using the CheckBox Web Control......Page 253
Q&A......Page 258
Workshop......Page 259
HOUR 12: Validating User Input with Validation Controls......Page 262
Examining the Need for User Input Validation......Page 263
Validating User Input in an ASP.NET Page......Page 265
Examining the RequiredFieldValidator Validation Control......Page 268
Examining the CompareValidator......Page 276
Using the RangeValidator......Page 283
Validating Input with the RegularExpressionValidator......Page 284
Formatting Properties for the Validation Web Controls......Page 287
A Look at the Remaining Validation Controls......Page 289
Q&A......Page 291
Workshop......Page 292
Part III: Working with Databases......Page 296
HOUR 13: Introducing Databases......Page 298
Examining Database Fundamentals......Page 299
Storing Structured Data......Page 300
Creating a New Database......Page 305
Creating Database Tables......Page 307
Adding Data to the Books Table......Page 313
Q&A......Page 317
Workshop......Page 318
HOUR 14: Accessing Data with the Data Source Web Controls......Page 320
Examining the Data Source Controls......Page 321
Delving into the SQL SELECT Statement......Page 329
Filtering and Sorting Data from the SqlDataSource Control’s Wizard......Page 338
Q&A......Page 345
Workshop......Page 346
An Overview of Data Web Controls......Page 348
Displaying Data with the GridView Control......Page 352
Showing One Record at a Time with the DetailsView......Page 362
Paging and Sorting with the GridView......Page 366
Q&A......Page 371
Workshop......Page 372
HOUR 16: Deleting, Inserting, and Editing Data......Page 374
Updating, Deleting, and Inserting Data with the SqlDataSource......Page 375
Looking at the Data-Modification SQL Statements......Page 378
Editing and Deleting Data with the GridView......Page 381
Inserting Data with the DetailsView......Page 400
Workshop......Page 403
HOUR 17: Working with Data-Bound DropDownLists, RadioButtons, and CheckBoxes......Page 408
An Overview of the List Web Controls......Page 409
Filtering Results Using the DropDownList......Page 416
Collecting User Input with CheckBoxLists and RadioButtonLists......Page 421
Workshop......Page 427
HOUR 18: Exploring Data Binding and Other Data-Related Topics......Page 430
Looking at the GridView and DetailsView’s Fields......Page 431
Using Wildcards in a WHERE Filter Expression......Page 441
An Examination of Data Binding......Page 444
Q&A......Page 451
Workshop......Page 453
HOUR 19: Using Templated Data Web Controls......Page 456
Displaying Data Using the ListView Control......Page 457
Paging and Sorting the ListView’s Data......Page 465
Displaying One Record at a Time with the FormView Control......Page 471
Q&A......Page 478
Workshop......Page 479
Part IV: Site Navigation, User Management, Page Layout, AJAX, and Deployment......Page 482
HOUR 20: Defining a Site Map and Providing Site Navigation......Page 484
An Overview of ASP.NET’s Site-Navigation Features......Page 485
Defining the Website’s Structure Using a Site Map......Page 486
Displaying a Breadcrumb with the SiteMapPath Control......Page 491
Showing the Entire Site Structure......Page 496
Q&A......Page 507
Workshop......Page 508
HOUR 21: Using Master Pages to Provide Sitewide Page Templates......Page 510
An Overview of Master Pages......Page 511
Creating a Master Page......Page 515
Creating a Content Page......Page 522
Providing Default Content in a Master Page......Page 525
Working with a Master Page’s Source Code Portion......Page 528
Workshop......Page 532
HOUR 22: Managing Your Site’s Users......Page 536
An Overview of User Accounts in ASP.NET......Page 537
Allowing Visitors to Create New User Accounts......Page 548
Signing In to the Website with the Login Control......Page 556
Displaying Content Based on Authentication Status......Page 560
Examining the ASP.NET Web Site Template......Page 562
Q&A......Page 565
Workshop......Page 566
HOUR 23: Building More Responsive Web Pages with ASP.NET Ajax......Page 570
An Overview of Ajax......Page 571
Using the ASP.NET Ajax Library......Page 573
Q&A......Page 583
Workshop......Page 584
HOUR 24: Deploying Your Website......Page 588
Choosing a Web-Hosting Company......Page 589
Visiting the Remote Website......Page 605
Q&A......Page 607
Workshop......Page 608
A......Page 610
B......Page 611
C......Page 612
D......Page 616
E......Page 620
F......Page 621
G......Page 622
H......Page 623
I......Page 624
L......Page 625
M......Page 628
O......Page 629
P......Page 630
R......Page 631
S......Page 632
T......Page 636
U......Page 638
V......Page 639
W–Z......Page 642

Polecaj historie