Chapters are PDF documents posted online at the book s Companion Website (located at

Similar documents
Chapters and Appendix F are PDF documents posted online at the book s Companion Website (located at

Deitel Series Page How To Program Series

Before You Begin. and Visual Basic 1

Visual Basic 2008 How to Program, 4/E Outline

Visual C# 2008 How to Program, 3/E Outline

Simply Visual Basic 2010

Contents. Illustrations. 1 Introduction to Computers, the Internet, the Web and C# 1

Subject to Change Drawing Application 1 Introducing Computers, the Internet and C#

3 Welcome Application 41 Introduction to Visual Programming

Before You Begin 1 Graphing Application 1 Introducing Computers, the Internet and Visual Basic.NET

Contents. Before You Begin. Object Technology: A Brief Review

Contents. 1 Introduction to Computers, the Internet. Before You Begin

ощ 'ршорвшэш! цвн-эориэу ощ 'sajbpossv # PIPG DUJ 'ssjmoossv ^ PIPG pipa w н OX ЛЮН VAV

Contents. 2 Introduction to C++ Programming,

CHAPTER 1: INTRODUCING C# 3

Contents. 1 Introduction to Computers, the Internet and the World Wide Web 1. 2 Introduction to C Programming 26

Contents. Before You Begin. Copyright by Pearson Education, Inc. All Rights Reserved.

C# Programming: From Problem Analysis to Program Design. Fourth Edition

CONTENTS. PART 1 Structured Programming 1. 1 Getting started 3. 2 Basic programming elements 17

Contents. Preface. Introduction. Introduction to C Programming

Appendices E through H are PDF documents posted online at the book s Companion Website (located at

CHAPTER 1: INTRODUCTION TO THE IDE 3

PESIT- Bangalore South Campus Hosur Road (1km Before Electronic city) Bangalore

Contents. Before You Begin. Appendices M Q are PDF documents posted online at the book s Companion Website (

Microsoft. Microsoft Visual C# Step by Step. John Sharp

This page intentionally left blank

Contents. 1 Introduction to Computers, the Internet and the Web 1

Deitel Series Page How To Program Series

MyProgram m i ng Lab. get with the programming. Through the power of practice and immediate personalized

Learning C# 3.0. Jesse Liberty and Brian MacDonald O'REILLY. Beijing Cambridge Farnham Köln Sebastopol Taipei Tokyo

Chapters and Appendices F J are PDF documents posted online at the book s Companion Website, which is accessible from.

Internet & World Wide Web

Beginning ASP.NET. 4.5 in C# Matthew MacDonald

Variable Scope The Main() Function Struct Functions Overloading Functions Using Delegates Chapter 7: Debugging and Error Handling Debugging in Visual

C++ How To Program 10 th Edition. Table of Contents

Welcome to Starting Out with Programming Logic and Design, Third Edition.

DOT NET Syllabus (6 Months)

Contents. Using Interpreters... 5 Using Compilers... 5 Program Development Life Cycle... 6

Microsoft Visual Studio 2010

"Charting the Course... MOC A Introduction to Web Development with Microsoft Visual Studio Course Summary

Microsoft Visual C# Step by Step. John Sharp

Global edition. Java How to Program. Late Objects Version. TENTH edition. Paul Deitel Harvey Deitel

Computer Programming C++ (wg) CCOs

CHAPTER 1 Introduction to Computers and Programming CHAPTER 2 Introduction to C++ ( Hexadecimal 0xF4 and Octal literals 031) cout Object

Programming Fundamentals - A Modular Structured Approach using C++ By: Kenneth Leroy Busbee

Object Oriented Design

Contents. Figures. Tables. Examples. Foreword. Preface. 1 Basics of Java Programming 1. xix. xxi. xxiii. xxvii. xxix

10267A CS: Developing Web Applications Using Microsoft Visual Studio 2010

COPYRIGHTED MATERIAL. Contents. Part I: C# Fundamentals 1. Chapter 1: The.NET Framework 3. Chapter 2: Getting Started with Visual Studio

A Web-Based Introduction

CERTIFICATE IN WEB PROGRAMMING

This course is designed for web developers that want to learn HTML5, CSS3, JavaScript and jquery.

Object-Oriented Programming and Data Structures

C# 2008 and.net Programming for Electronic Engineers - Elektor - ISBN

"Charting the Course to Your Success!" MOC B Programming in C# Course Summary

DOT NET SYLLABUS FOR 6 MONTHS

SAP' ABAP. Handbook. Kogent Learning Solutions, Inc. Sudbury, Massachusetts JONES AND BARTLETT PUBLISHERS BOSTON TORONTO LONDON SINUAPORI:

Building Java Programs

Object-Oriented Programming in C# (VS 2015)

Preface... (vii) CHAPTER 1 INTRODUCTION TO COMPUTERS

Object-Oriented Programming in C# (VS 2012)


Apex TG India Pvt. Ltd.

[CHAPTER] 1 INTRODUCTION 1

Cowley College & Area Vocational Technical School

This page intentionally left blank

SOME ASSEMBLY REQUIRED

C#.NET TRAINING / /

20483BC: Programming in C#

LIST OF EXPERIMENTS. (1) (Office Automation)

Contents. More Controls 51. Visual Basic 1. Introduction to. xiii. Modify the Project 30. Print the Project Documentation 35

10267 Introduction to Web Development with Microsoft Visual Studio 2010

Standard. Number of Correlations

.NET FRAMEWORK. Visual C#.Net

PROBLEM SOLVING WITH FORTRAN 90

INTRODUCTION TO.NET. Domain of.net D.N.A. Architecture One Tier Two Tier Three Tier N-Tier THE COMMON LANGUAGE RUNTIME (C.L.R.)

Course 80436A C/Side Introduction in Microsoft Dynamics NAV 2013

.NET Advance Package Syllabus

Table of Contents. Preface... xxi

.NET, C#, and ASP.NET p. 1 What Is.NET? p. 2 The Common Language Runtime p. 2 Introducing C# p. 3 Introducing ASP.NET p. 4 Getting Started p.

Microsoft Visual C# 2005: Developing Applications Table of Contents

DOT NET TRAINING PROGRAM

ASP.NET 2.0 p. 1.NET Framework 2.0 p. 2 ASP.NET 2.0 p. 4 New Features p. 5 Special Folders Make Integration Easier p. 5 Security p.

Murach s Beginning Java with Eclipse

Developing Web Applications Using Microsoft Visual Studio 2008 SP1

Course Text. Course Description. Course Objectives. StraighterLine Introduction to Programming in C++

Prelude to Programming

Introduction... 1 Part I: Getting Started with Excel VBA Programming Part II: How VBA Works with Excel... 31


Syllabus- Java + Android. Java Fundamentals

Windows Presentation Foundation Programming Using C#

ASP.NET Web Forms Programming Using Visual Basic.NET

The C# Programming Language. Overview

.Net. Course Content ASP.NET

DE Introduction to Web Development with Microsoft Visual Studio 2010

Jim Jackson II Ian Gilman

The course introduces many of the techniques and technologies employed by modern desktop and enterprise applications, including:

Type of Classes Nested Classes Inner Classes Local and Anonymous Inner Classes

"Charting the Course... MOC A Developing Data Access Solutions with Microsoft Visual Studio Course Summary

Course Description. Audience. Module Title : 20483B: Programming in C# Duration : 5 days. Course Outline :: 20483B ::

Transcription:

vbhtp6printonlytoc.fm Page ix Wednesday, February 27, 2013 11:59 AM Chapters 16 31 are PDF documents posted online at the book s Companion Website (located at www.pearsonhighered.com/deitel/). Preface Before You Begin xvii xxxi 1 Introduction to Computers, the Internet and Visual Basic 1 1.1 Introduction 2 1.2 Hardware and Moore s Law 2 1.3 Data Hierarchy 3 1.4 Computer Organization 5 1.5 Machine Languages, Assembly Languages and High-Level Languages 7 1.6 Object Technology 8 1.7 Internet and World Wide Web 10 1.8 Visual Basic 11 1.8.1 Object-Oriented Programming 12 1.8.2 Event-Driven Programming 12 1.8.3 Visual Programming 12 1.8.4 Internet and Web Programming 13 1.8.5 Other Key Contemporary Programming Languages 13 1.9 Microsoft s.net 14 1.9.1.NET Framework 14 1.9.2 Common Language Runtime 14 1.10 Microsoft s Windows Operating System 14 1.11 Windows Phone 8 for Smartphones 16 1.11.1 Selling Your Apps in the Windows Phone Marketplace 16 1.11.2 Free vs. Paid Apps 16 1.11.3 Testing Your Windows Phone Apps 17 1.12 Windows Azure and Cloud Computing 17 1.13 Visual Studio Integrated Development Environment 17 1.14 Test-Driving the Visual Basic Advanced Painter App in Visual Studio 2012 18 2 Dive Into Visual Studio Express 2012 for Windows Desktop 26 2.1 Introduction 27

vbhtp6printonlytoc.fm Page x Wednesday, February 27, 2013 11:59 AM x 2.2 Overview of the Visual Studio 2012 IDE 27 2.3 Menu Bar and Toolbar 32 2.4 Navigating the Visual Studio IDE 35 2.4.1 Solution Explorer 37 2.4.2 Toolbox 38 2.4.3 Properties Window 39 2.5 Using Help 40 2.6 Using Visual App Development to Create a Simple App that Displays Text and an Image 41 2.7 Wrap-Up 51 2.8 Web Resources 51 3 Introduction to Visual Basic Programming 59 3.1 Introduction 60 3.2 Programmatically Displaying Text in a Label 61 3.2.1 Analyzing the Program 62 3.2.2 Modifying ASimpleApp to Programmatically Change the Label s Text Property 64 3.3 Addition Program 68 3.4 Building the Addition Program 71 3.5 Memory Concepts 78 3.6 Arithmetic 79 3.7 Decision Making: Equality and Relational Operators 83 3.8 Wrap-Up 88 4 Introduction to Problem Solving and Control Statements 101 4.1 Introduction 102 4.2 Algorithms 102 4.3 Pseudocode Algorithm 103 4.4 Control Structures 103 4.5 If Then Selection Statement 106 4.6 If Then Else Selection Statement 107 4.7 Nested If Then Else Selection Statements 108 4.8 Repetition Statements 109 4.9 Compound Assignment Operators 111 4.10 Formulating Algorithms: Counter-Controlled Repetition 113 4.11 Formulating Algorithms: Nested Control Statements 119 4.12 Using the Debugger: Locating a Logic Error 125 4.12.1 Breakpoints and Running the Program 127 4.12.2 Data Tip Box 128 4.12.3 Locals Window 128 4.12.4 Using the Step Over Command to Execute Statements 129 4.13 Wrap-Up 130

vbhtp6printonlytoc.fm Page xi Wednesday, February 27, 2013 11:59 AM xi 5 Problem Solving and Control Statements: Part 2 146 5.1 Introduction 147 5.2 For Next Repetition Statement 147 5.2.1 For Next Statement Header Components 149 5.2.2 General Form of a For Next Statement 149 5.2.3 Declaring the Control Variable Before a For Next Statement 150 5.2.4 Using Expressions in the For Next Statement s Header 150 5.2.5 For Next Statement UML Activity Diagram 150 5.2.6 Local Type Inference 150 5.3 Examples Using the For Next Statement 152 5.4 App: Interest Calculator 152 5.5 Formulating Algorithms: Nested Repetition Statements 156 5.6 Select Case Multiple-Selection Statement 159 5.7 Do Loop While and Do Loop Until Repetition Statements 164 5.8 Using Exit to Terminate Repetition Statements 165 5.9 Using Continue in Repetition Statements 166 5.10 Logical Operators 166 5.11 App: Dental Payment Calculator 169 5.12 Wrap-Up 173 6 Methods 188 6.1 Introduction 189 6.2 Classes and Methods 189 6.3 Subroutines: Methods That Do Not Return a Value 191 6.4 Functions: Methods That Return a Value 195 6.5 Implicit Argument Conversions 197 6.6 Option Strict and Data-Type Conversions 198 6.7 Passing Arguments: Pass-by-Value vs. Pass-by-Reference 200 6.8 Scope of Declarations 203 6.9 Case Study: Random-Number Generation 206 6.9.1 Scaling and Shifting of Random Numbers 208 6.9.2 Randomly Selecting Images 209 6.9.3 Rolling Dice Repeatedly and Displaying Statistics 211 6.10 Case Study: A Game of Chance 213 6.11 Method Overloading 218 6.12 Optional Parameters 220 6.13 Using the Debugger: Debugging Commands 223 6.14 Wrap-Up 224 7 Arrays 238 7.1 Introduction 239 7.2 Arrays 239 7.3 Declaring and Allocating Arrays 240 7.4 Initializing the Values in an Array 241 7.5 Summing the Elements of an Array 242

vbhtp6printonlytoc.fm Page xii Wednesday, February 27, 2013 11:59 AM xii 7.6 Using Arrays to Analyze Survey Results 243 7.7 Die-Rolling App with an Array of Counters 246 7.8 Case Study: Flag Quiz 248 7.9 Passing an Array to a Method 252 7.10 For Each Next Repetition Statement 255 7.11 Sorting an Array with Method Sort of Class Array 257 7.12 Searching an Array with Linear Search 259 7.13 Searching a Sorted Array with Array Method BinarySearch 261 7.14 Rectangular Arrays 262 7.15 Case Study: Maintaining Grades Using a Rectangular Array 264 7.16 Resizing an Array with the ReDim Statement 274 7.17 Wrap-Up 275 8 Files 286 8.1 Introduction 287 8.2 Data Hierarchy 287 8.3 Files and Streams 289 8.4 Test-Driving the Credit Inquiry App 290 8.5 Writing Data Sequentially to a Text File 292 8.5.1 Class CreateAccounts 295 8.5.2 Opening the File 296 8.5.3 Managing Resources with the Using Statement 297 8.5.4 Adding an Account to the File 298 8.5.5 Closing the File and Terminating the App 299 8.6 Building Menus with the Windows Forms Designer 300 8.7 Credit Inquiry App: Reading Data Sequentially from a Text File 302 8.7.1 Implementing the Credit Inquiry App 302 8.7.2 Selecting the File to Process 302 8.7.3 Specifying the Type of Records to Display 303 8.7.4 Displaying the Records 304 8.8 Wrap-Up 307 9 Object-Oriented Programming: Classes and Objects 312 9.1 Introduction 313 9.2 Classes, Objects, Methods and Instance Variables 313 9.3 Account Class 314 9.4 Value Types and Reference Types 320 9.5 Case Study: Card Shuffling and Dealing Simulation 321 9.6 Case Study: Time Class 327 9.7 Class Scope 334 9.8 Object Initializers 335 9.9 Auto-Implemented Properties 335 9.10 Using Me to Access the Current Object 336 9.11 Garbage Collection 336

vbhtp6printonlytoc.fm Page xiii Wednesday, February 27, 2013 11:59 AM xiii 9.12 Shared Class Members 337 9.13 Const and ReadOnly Fields 340 9.14 Shared Methods and Class Math 341 9.15 Object Browser 342 9.16 Wrap-Up 342 10 Object-Oriented Programming: Inheritance and Polymorphism 352 10.1 Introduction 353 10.2 Base Classes and Derived Classes 353 10.3 Business Case Study: Commission Employees Class Hierarchy 355 10.3.1 Creating Base Class CommissionEmployee 355 10.3.2 Creating Derived Class BasePlusCommissionEmployee 358 10.3.3 Testing Class BasePlusCommissionEmployee 361 10.4 Constructors in Derived Classes 363 10.5 Protected Members 363 10.6 Introduction to Polymorphism: A Polymorphic Video Game 364 10.7 Abstract Classes and Methods 365 10.8 Case Study: Payroll System Class Hierarchy Using Polymorphism 366 10.8.1 Abstract Base Class Employee 367 10.8.2 Concrete Derived Class SalariedEmployee 369 10.8.3 Concrete Derived Class CommissionEmployee 370 10.8.4 Indirect Concrete Derived Class BasePlusCommissionEmployee 372 10.8.5 Demonstrating Polymorphic Processing 373 10.9 Online Case Study: Interfaces 375 10.10 Wrap-Up 376 11 Introduction to LINQ 382 11.1 Introduction 383 11.2 Querying an Array of Primitive-Type Elements Using LINQ 384 11.3 Querying an Array of Reference-Type Elements Using LINQ 387 11.4 Deferred Execution and Transforming Query Results 393 11.5 LINQ Resource Center 394 11.6 Wrap-Up 395 12 Databases and LINQ 399 12.1 Introduction 400 12.2 Relational Databases 401 12.3 A Books Database 402 12.4 LINQ to Entities and the ADO.NET Entity Framework 406 12.5 Querying a Database with LINQ 407 12.5.1 Creating the ADO.NET Entity Data Model Class Library 408 12.5.2 Creating a Windows Forms Project and Configuring It to Use the Entity Data Model 412

vbhtp6printonlytoc.fm Page xiv Wednesday, February 27, 2013 11:59 AM xiv 12.5.3 Data Bindings Between Controls and the Entity Data Model 414 12.6 Dynamically Binding Query Results 419 12.6.1 Creating the Display Query Results GUI 420 12.6.2 Coding the Display Query Results App 421 12.7 Retrieving Data from Multiple Tables with LINQ 423 12.8 Creating a Master/Detail View App 428 12.8.1 Creating the Master/Detail GUI 429 12.8.2 Coding the Master/Detail App 431 12.9 Address Book Case Study 432 12.9.1 Creating the Address Book App s GUI 433 12.9.2 Coding the Address Book App 434 12.10 Tools and Web Resources 438 12.11 Wrap-Up 438 13 Web App Development with ASP.NET 446 13.1 Introduction 447 13.2 Web Basics 448 13.3 Multitier App Architecture 449 13.4 Your First Web App 451 13.4.1 Building the WebTime App 453 13.4.2 Examining WebTime.aspx s Code-Behind File 462 13.5 Standard Web Controls: Designing a Form 462 13.6 Validation Controls 467 13.7 Session Tracking 473 13.7.1 Cookies 475 13.7.2 Session Tracking with HttpSessionState 475 13.7.3 Options.aspx: Selecting a Programming Language 477 13.7.4 Recommendations.aspx: Displaying Recommendations Based on Session Values 481 13.8 Case Study: Database-Driven ASP.NET Guestbook 482 13.8.1 Building a Web Form that Displays Data from a Database 484 13.8.2 Modifying the Code-Behind File for the Guestbook App 489 13.9 Online Case Study: ASP.NET AJAX 490 13.10 Online Case Study: Password-Protected Books Database App 491 13.11 Wrap-Up 491 14 Windows Forms GUI: A Deeper Look 498 14.1 Introduction 499 14.2 Controls and Components 499 14.3 Creating Event Handlers 501 14.4 Control Properties and Layout 503 14.5 GroupBoxes and Panels 506 14.6 ToolTips 508 14.7 Mouse-Event Handling 510 14.8 Keyboard-Event Handling 513

vbhtp6printonlytoc.fm Page xv Wednesday, February 27, 2013 11:59 AM xv 14.9 Menus 516 14.10 MonthCalendar Control 525 14.11 DateTimePicker Control 526 14.12 LinkLabel Control 529 14.13 ListBox and CheckedListBox Controls 531 14.14 Multiple Document Interface (MDI) Windows 535 14.15 Visual Inheritance 543 14.16 Animation with the Timer Component 546 14.17 Wrap-Up 547 15 Graphics and Multimedia 554 15.1 Introduction 555 15.2 Drawing Classes and the Coordinate System 555 15.3 Graphics Contexts and Graphics Objects 556 15.4 Colors 557 15.5 Fonts 564 15.6 Drawing Lines, Rectangles and Ovals 568 15.7 Drawing Arcs 571 15.8 Drawing Polygons and Polylines 574 15.9 Additional Brush Types 575 15.10 Loading, Displaying and Scaling Images 580 15.11 Windows Media Player 582 15.12 Printing 583 15.13 Wrap-Up 589 Online Chapters 597 A Operator Precedence Chart 598 B Primitive Types 600 C Number Systems 601 C.1 Introduction 602 C.2 Abbreviating Binary Numbers as Octal and Hexadecimal Numbers 605 C.3 Converting Octal and Hexadecimal Numbers to Binary Numbers 606 C.4 Converting from Binary, Octal or Hexadecimal to Decimal 606 C.5 Converting from Decimal to Binary, Octal or Hexadecimal 607 C.6 Negative Binary Numbers: Two s-complement Notation 609 D ASCII Character Set 613 E Unicode 614 E.1 Introduction 615

vbhtp6printonlytoc.fm Page xvi Wednesday, February 27, 2013 11:59 AM xvi E.2 Unicode Transformation Formats 616 E.3 Characters and Glyphs 617 E.4 Advantages/Disadvantages of Unicode 618 E.5 Using Unicode 618 E.6 Character Ranges 620 F Creating Console Applications 625 F.1 Introduction 625 F.2 A Simple Console Application 625 F.3 Creating a Console Application 626 Index 629 Companion Website Online Content Chapters 16 31 and Appendix F are PDF documents posted online at the book s Companion Website (located at www.pearsonhighered.com/deitel). 16 Exception Handling: A Deeper Look 16-1 17 Strings and Characters: A Deeper Look 17-1 18 Files and Streams: A Deeper Look 18-1 19 XML and LINQ to XML 19-1 20 Windows 8 UI 20-1 21 Windows 8 Graphics and Multimedia 21-1 22 Windows Phone 8 Case Study 22-1 23 Introduction to Concurrency: Async and Await 23-1 24 Web App Development with ASP.NET: A Deeper Look 24-1 25 Web Services 25-1 26 Windows Azure Cloud Computing Case Study 26-1 27 Windows Presentation Foundation (WPF) GUI 27-1 28 WPF Graphics and Multimedia 28-1 29 Data Structures and Generic Collections 29-1 30 ATM Case Study, Part 1: Object-Oriented Design with the UML 30-1 31 ATM Case Study, Part 2: Implementing an Object-Oriented Design 31-1