ASP.NET.3.5.Unleashed.pdf

所需积分/C币:3 2013-12-24 09:45:48 25.41MB PDF
6
收藏 收藏
举报

ASP.NET.3.5.Unleashed.pdf
aspnet 3.5 Unleashed Editor-in-Chief Copyright o 2008 by Sams Publishing Karen Gettman All rights reserved. No part of this book shall be reproduced stored in a retrieval system, or transmitted by any means, electronic, mechanical, photocopying, recording, Senior Acquisitions or otherwise, without written permission from the publisher. No patent liability is Editor assumed with respect to the use of the information contained herein Although every Neil rowe precaution has been taken in the preparation of this book, the publisher and author assume no responsibility for errors or omissions. Nor is any liability assumed for Development Editor damages resulting from the use of the information contained herein Mark renfrow SBN13:9780672330117 SBN10:0-672330113 Managing Editor Gina Kanouse Library of Congress Cataloging-in-Publication Data Walther, Stephen Project Editors sPnet 3.5 unleashed/ stephen Walther Lori Lyons p. cm Anne goebel Includes index SBN0672330113 Copy Editor 1. Active server pages. 2. Web sites-Design. 3. Web site development Bart reed 4. Microsoft. net. I. Title Indexer TK51058885A26W35162007 005.2’76-dc22 Erika millen 2007046046 Proofreaders Printed in the United states on america Terrest Publishing First Printing December 2007 San dee phillips Trademarks Technical Editor all terms mentioned in this book that are known to be trademarks or service marks Todd meister have been appropriately capitalized. Sams Publishing cannot attest to the accuracy of this information Use of a term in this book should not be regarded as affecting the Publishing validity of any trademark or service mark. Coordinator Warning and Disclaimer Cindy Teeters Every effort has been made to make this book as complete and as accurate as Multimedia Developer possible, but no warranty or fitness is implied The information provided is on anas is"basis. The author and the publisher shall have neither liability nor responsibility to Dan scherf any person or entity with respect to any loss or damages arising from the information contained in this book or from the use of the Cd or programs accompanying it Book Designer Gary Adair Bulk sales Sams Publishing offers excellent discounts on this book when ordered in quantity for Composition bulk purchases or special sales. For more information, please contact Jake mcfarland U.S. Corporate and government sales 18003823419 corpsales@pearsontechgroup.com For sales outside of the U.s., please contact International sales international@ pearsoned com Contents at a glance Introduction Part I Building ASPNET Pages 1 Overview of the asp. net framework 7 2 USing the Standard controls 61 3 Using the validation controls 123 4 USing the rich Controls 181 Part I Designing ASP.NET Websites 5 Designing Websites with Master Pages 237 6 Designing Websites with Themes 269 7 Creating Custom Controls with User Controls 297 Part Il Performing Data Access 8 Overview of data access 337 9 USing the SqlData Source Control 379 10 USing list Controls 437 11 Using the grid view Control 481 12 USing the details view and Form view Controls 563 13 USing the Repeater and Datalist Controls 619 14 USing the listView and DataPager Controls 657 Part Iv Building components 15 Building Components 687 16 USing the ObjectData Source Control 737 17 Building data access components with ado. net 809 8 Data Access with linQ to SQL 901 Part v Site Navigation 19 USing the Navigation Controls 971 20 USing Site Maps 1041 21 Advanced Navigation 1081 Part VI Security 22 USing the Login Controls 1103 23 Using ASP.NET Membership 1161 Part Vl Building ASP.NET Applications 24 Maintaining Application State 1221 25 Caching Application Pages and Data 1289 26 Localizing Applications for Multiple Languages 1369 27 woRking with the Http runtime 1403 28 Configuring Applications 1443 Part Vil Custom Control Building 29 Building Custom Controls 1499 30 Building Templated Databound Controls 1569 Part x ASPNET AJAX 31 USing Server-Side AsP. NET AjAX 1597 32 USing the AsP. NEt AJAX Control Toolkit 1657 33 USing Client-Side ASP. NET AJAX 1695 Part x Sample Application 34 Building a Code sample Website 1773 Index 1797 Table of contents Introduction Who should read this book? What do you need to know before you read this book? Changes to This book 11123 How This book Is organized Part I Building ASP. NET Pages 1 overview of the asp net framework ASP Net and the. Net framework Understanding the Framework Class Library Understanding the Common Language runtime 18 Understanding asp. net Controls 20 Overview of asp. net controls 20 Understanding HTML Controls 22 Understanding and Handling Control Events 23 Understanding View State 29 Understanding ASP.NET Pages 35 Understanding Dynamic Compilation 35 Understanding Control Trees 38 Using Code- Behind Pages 40 Handling page events 45 Using the page. IsPostBack property 48 Debugging and Tracing ASP.NET Pages 49 Tracing p g age execution 54 Installing the asP. net framework Summary 5 2 Using the Standard Controls 61 Displa ying Using the Label Control 61 USing the literal Ce Accepting User Input 70 Using the TextBox Control 70 Using the CheckBox Control 78 USing the radio Button Control 81 aSP net 3.5 Unleashed Submitting Form Data 86 Using the button control 86 Using the linkButton Control 88 Using the lmagebutton control 91 Using client scripts with Button Controls 95 Performing cross-Page posts 98 Specifying a Default Button 102 Handling the Command event 103 Displaying images 106 Using the Image control 106 Using the ImageMap Control 108 Using the panel control 113 Using the Hyperlink Control 120 Summary 122 3 Using the Validation Controls 123 Overview of the validation controls 123 Validation Controls and javascript 128 Using Page Is Valid 128 Setting the Display property 129 Highlighting Validation Errors 130 Using Validation Groups 135 Disabling Validation 140 Using the requiredFieldvalidator Control 141 Using the range validator control 145 Using the Compare Validator Control 147 Using the RegularExpression Validator Control 153 Using the custom Validator Control 156 Using the ValidationSummary Control 164 Creating Custom Validation Controls 69 Creating a Length Validator Control 169 Creating an Ajax Validator Control 172 Summary 179 4 Using the rich Controls 181 Accepting File Uploads 181 Saving Files to the File System 183 Saving Files to a database 186 Uploading Large files 191 Displaying a Calendar 197 Creating a Pop-up Date Picker 201 Rendering a Calendar from a database table 204 Contents Displaying Advertisements 208 Storing Advertisements in an XML File 209 Storing advertisements in a Database table 213 Tracking impressions and transfers 215 Displaying Different Page views 221 Displaying a tabbed page view 222 Displaying a multi-Part Form 225 Displaying a wizard 227 Summary 232 Part l Designing ASP.NET Websites 5 Designing Websites with Master Pages 237 Creating Master Pages 238 Creating Default Content 242 Nesting master pa 245 USing Images and Hyperlinks in Master Pages 251 Registering Master Pages in Web Configuration 254 Modifying Master Page Content 255 Using the Title attribut 255 Using the Page Header Property 256 Exposing master page properties 258 USing Find control with Master Pages 261 Loading master Pages dynamicall 263 Loading Master Pages Dynamically for Multiple Content Pages..266 Summary 267 6 Designing Websites with Themes 269 Creating Themes 270 Adding skins to Themes 270 Creating named skins 272 Themes versus stylesheetThemes 275 Disabling Themes 276 Registering Themes in the Web Configuration File 279 Adding cascading style sheets to Themes 280 Adding Multiple Cascading Style Sheets to a Theme 284 Changing Page Layouts with Cascading Style Sheets 284 Creating global themes 289 Applying Themes dynamically 290 Applying Skins Dynamically 292 Summary 296 aSP net 3.5 Unleashed 7 Creating Custom Controls with User Controls 297 Creating User Controls 298 Registering User Controls in the Web Configuration File 301 Exposing properties from a User control 302 Exposing Events from a User Control 305 Creating an Address Form Control 309 AJAX and User Controls 315 Dynamically loading user controls 318 Using the reference directive 319 Creating a multi-Page wizard 324 Summary 333 Part ll Performing Data Access 8 Overview of data access 337 USing Data Bound controls 337 Working with list Controls 338 Working with Tabular Data Bound Control 341 Working with Hierarchical Data Bound controls 345 Working with other controls 348 Using data Source controls 350 Using asp.net parameters with Data Source Controls 352 Using Programmatic Data Binding 355 Understanding Templates and Data Binding Expressions 357 Using Templates 357 Using data binding expressions 361 Using Two-Way Data Binding Expressions 364 Overview of SQL Server 2005 Express 367 Features of SQL Server Express 367 SQL Server 2005 Express Management Tools 368 Server databases versus local databases 370 Sample Database-Driven Web Application 373 Summary 376 9 Using the sqldata Source Control 379 Creating database Connections 380 Connecting to Microsoft SQL Server 380 Connecting to other Databases 384 Storing Connection Strings in the Web Configuration File 386 Encrypting Connection Strings 387 Contents Executing Database Commands 389 Executing Inline sol statements 389 Executing Stored procedures 392 Filtering database rows 394 Changing the Data Source Mode 397 Handling sol command execution errors 398 Canceling Command Execution 402 USing ASP.NET Parameters with the SqlDataSource Control 405 Using the asP. net Parameter Object 406 Using the Asp.nET ControlParameter Object 409 Using the asp.nEt CookieParameter Object 414 Using the asp.net FormParameter Object 416 Using the AsP.NET ProfileParameter Object 418 Using the QueryStringParameter Object 421 Using the SessionParameter Object 423 Programmatically Executing SqlDataSource Commands 425 Adding ado. NEt parameters 425 Executing Insert, Update, and Delete Commands 427 Executing Select Commands 429 Caching database Data with the Sqldata Source Control 434 Summary 436 o Using List Controls 437 Overview of the list controls 437 Declare ng List items 437 Binding to a Data Source 440 Determining the selected list item 443 Appending Data Items 448 Enabling Automatic PostBacks 450 Using the items collection 451 Working with the dropdownlist control g 455 Working with the radio Buttonlist control 457 g 460 Working with the checkBoxlist Control 464 cking with the bulletedList Control 466 ting a Custom 471 Summary 480

...展开详情
试读 127P ASP.NET.3.5.Unleashed.pdf
立即下载 身份认证后 购VIP低至7折
一个资源只可评论一次,评论内容不能少于5个字
您会向同学/朋友/同事推荐我们的CSDN下载吗?
谢谢参与!您的真实评价是我们改进的动力~
关注 私信
上传资源赚钱or赚积分
最新推荐
ASP.NET.3.5.Unleashed.pdf 3积分/C币 立即下载
1/127
ASP.NET.3.5.Unleashed.pdf第1页
ASP.NET.3.5.Unleashed.pdf第2页
ASP.NET.3.5.Unleashed.pdf第3页
ASP.NET.3.5.Unleashed.pdf第4页
ASP.NET.3.5.Unleashed.pdf第5页
ASP.NET.3.5.Unleashed.pdf第6页
ASP.NET.3.5.Unleashed.pdf第7页
ASP.NET.3.5.Unleashed.pdf第8页
ASP.NET.3.5.Unleashed.pdf第9页
ASP.NET.3.5.Unleashed.pdf第10页
ASP.NET.3.5.Unleashed.pdf第11页
ASP.NET.3.5.Unleashed.pdf第12页
ASP.NET.3.5.Unleashed.pdf第13页
ASP.NET.3.5.Unleashed.pdf第14页
ASP.NET.3.5.Unleashed.pdf第15页
ASP.NET.3.5.Unleashed.pdf第16页
ASP.NET.3.5.Unleashed.pdf第17页
ASP.NET.3.5.Unleashed.pdf第18页
ASP.NET.3.5.Unleashed.pdf第19页
ASP.NET.3.5.Unleashed.pdf第20页

试读结束, 可继续阅读

3积分/C币 立即下载