《Microsoft Visual Basic6.0分布式应用程序开发 影印第2版》PDF下载

  • 购买积分:15 如何计算积分?
  • 作  者:Microsoft 公司著
  • 出 版 社:北京:北京大学出版社
  • 出版年份:2000
  • ISBN:7900629025
  • 页数:486 页
图书介绍:

Chapter 1:Application Design Concepts 1

About This Chapter 1

Before You Begin 1

Lesson 1:Planning a Distributed Solution 2

Overview of Microsoft Solutions Framework 2

The Solutions Design Model 3

Software Requirements 5

Practice:Adding Visual SourceSafe to Visual Basic 9

Multiple Developer Tools 9

Lesson Summary 12

Lesson 2:Selecting an Application Architecture 13

Understanding Application Structure 13

Developing a Distributed Application 17

Lesson Summary 21

Lesson 3:Using Visual Database Tools 22

Using Visual Database Tools with Visual Studio 22

Practice:Tour of the SQL Server Pubs database 25

Deriving Physical Design Using Visual Database Tools 25

Lesson Summary 27

Summary 28

Lab:Using Visual Component Manager 29

Review 31

Chapter 2:Creating the User Interface 33

About This Chapter 33

Before You Begin 33

Lesson 1:Overview of User Interface Elements 34

Controls 34

Setting Properties 39

Managing Events 41

Standard Form Events 42

Using Collections 44

Practice:Using the Collection Object s Add Method 46

Lesson Summary 48

Developing Navigation 49

Lesson 2:Navigation and Validation 49

Validating Data 52

Lesson Summary 54

Summary 55

Lab:Creating a User Interface Dynamically 56

Exercise 1:Creating the User Interface 56

Exercise 2:Validating User Input 59

Exercise 3:Adding and Coding a Menu Bar 60

Exercise 4:Dynamically Adding Controls 62

Review 64

Chapter 3:Creating COM DLLs with Visual Basic 65

About This Chapter 65

Before You Begin 65

Lesson 1:Creating Class Modules 66

Creating Properties,Methods,and Events 66

Call-Back Methods 69

Events 69

Enumerations 70

Practice:Using the Class Builder Utility 71

Lesson Summary 76

Lesson 2:Using Class Modules 77

Using the Object Browser 77

Practice:Viewing the CFile Class 77

Instantiating a Class 78

Practice:Using a Component s Properties,Methods,and Events 81

Lesson Summary 83

Lesson 3:Creating COM DLLs and EXEs 84

ActiveX Project Templates 84

Setting ActiveX DLL Project Properties 85

Setting Class Properties in a Component 90

Registering and Unregistering Components 93

Testing and Debugging Components 96

Practice:Using a Project Group to Test a COM DLL 96

Lesson Summary 98

Summary 100

Lab:Creating a COM DLL 101

Review 104

Chapter 4:Advanced COM Programming with Visual Basic 6.0 105

About This Chapter 105

Before You Begin 105

Lesson 1:Creating Custom Interfaces 106

Interface-Based Programming 106

Interfaces and Visual Basic 108

Practice:Viewing a Type Library with the OLE View Tool 111

Creating Your Own Interfaces 112

Polymorphism 115

Version Compatibility 117

Lesson Summary 121

Lesson 2:Developing a Custom Object Model 123

Custom Business Objects 124

Creating an Object Model 125

Collection Classes 127

Visual Basic Object Modeling Tools 128

Practice:Creating Object Models with the Class Builder Utility 129

Lesson Summary 131

Summary 132

Lab:Advanced COM Programming with Visual Basic 133

Exercise 1:Creating the IEmployee Interface 133

Exercise 2:Implementing the IEmployee Interface 134

Exercise 3:Testing the PayRoll Component 136

Review 141

Chapter 5:Introducing ActiveX Data Objects 143

About This Chapter 143

Before You Begin 143

Lesson 1:Overview of Universal Data Access 144

Overview of Universal Data Access 144

ActiveX Data Objects 147

Lesson Summary 148

Lesson 2:Introduction to the ADO Object Model 149

Creating ADO Objects 149

The ADO Connection Object 151

The ADO Command Object 151

The ADO Recordset Object 151

Lesson Summary 153

Lesson 3:Using the Data Environment 154

The Data Environment Designer 154

Practice:Data Binding Using a Data Environment 160

Lesson Summary 165

Summary 166

Lab:Using the Data Environment and ADO 167

Review 171

Chapter 6:Accessing Data with ActiveX Data Objects 173

About This Chapter 173

Before You Begin 173

Establishing a Connection 174

Lesson 1:Managing Connections to a Data Source 174

Defining the ADO Connection Object 174

Practice:Programmatically Creating a Connection 177

Using the ADO Command Object 178

Lesson Summary 180

Lesson 2:Returning Records from a Data Source 181

Using the ADO Recordset Object 181

Accessing Records in a Recordset 184

Binding Controls to ADO Recordsets 185

Creating Multiple Recordsets 185

Creating Programmatic Recordsets 187

Lesson Summary 189

Lesson 3:Navigating Records 190

ADO Navigation Properties 190

ADO Navigation Methods 191

Practice:Navigating an ADO Recordset 191

Lesson Summary 195

Lesson 4:Modifying Records 196

Modifying Records with SQL statements 196

Modifying Records in a Recordset 197

Lesson Summary 198

Summary 199

Lab:Accessing Data Using ADO Objects 200

Exercise 1:Creating the COM Component that Uses ADO 200

Exercise 2:Creating the Client 202

Review 204

Chapter 7:Advanced Database Topics 205

About This Chapter 205

Before You Begin 205

Lesson 1:Introduction to Transactions 206

Definition of a Transaction 206

Transactions and ADO 207

Types of Transactions 208

Coding Efficient Transactions 210

Transact-SQL 212

Lesson Summary 214

Lesson 2:Using Disconnected Recordsets 215

Specifying the CursorLocation Property 216

Disconnecting from a Data Source 218

Reconnecting to a Data Source 219

Practice:Working With Disconnected Recordsets 221

Lesson Summary 229

Lesson 3:Asynchronous Operations 230

Connecting Asynchronously to a Data Source 230

Using ADO Events 232

Asynchronously Executing a Command 234

Asynchronously Fetching Results 236

Lesson Summary 239

Summary 240

Lab:Using Disconnected Recordsets 241

Review 243

Chapter 8:Using Stored Procedures 245

About This Chapter 245

Before You Begin 245

Lesson 1:Overview of Stored Procedures 246

Advantages of Using Stored Procedures 246

Stored Procedures in a Two-Tier Model 247

Stored Procedures in an N-Tier Model 248

Stored Procedures and the Command Object 250

Practice:Calling a Stored Procedure 251

Lesson Summary 254

Lesson 2:Using Stored Procedures 255

Creating Simple Stored Procedures 255

Using Parameters in Stored Procedures 259

Generating Multiple Recordsets 260

Implementing Transactions 261

Debugging Transact-SQL 261

Lesson Summary 263

Summary 264

Lab:Creating and Calling a Stored Procedure 265

Exercise 1:Creating a Data Access Component 265

Exercise 2:Creating the Front-End Application 266

Review 270

Chapter 9:Using Microsoft Transaction Server 271

About This Chapter 271

Before You Begin 271

Lesson 1:Overview of Microsoft Transaction Server 272

Developing N-tier Applications with MTS 273

MTS Services 274

An MTS Application Example 279

Lesson Summary 280

Lesson 2:Installing and Configuring Microsoft Transaction Server 281

MTS System Requirements 282

Configuring Your MTS Server 283

Configuring Your Development Computer 285

Lesson Summary 288

Lesson 3:Creating Solutions Using Microsoft Transaction Server 289

Designing MTS Components 289

Creating MTS Components 290

Using Transactions in MTS Components 293

Deploying MTS Components 296

Lesson Summary 298

Summary 299

Lab:Creating and Deploying MTS Components 300

Exercise 1:Setting up the Chateau Database 300

Exercise 2:Creating the Client Application 302

Exercise 3:Creating the Chateau COM DLL 303

Exercise 4:Deploying Your COM DLL with MTS 307

Review 309

About This Chapter 311

Before You Begin 311

Chapter 10:Implementing Security in the Enterprise 311

Lesson 1:Overview of Security 312

Principles of Security 312

Windows NT Security Model 313

Enterprise Application Security 314

Lesson Summary 318

Lesson 2:Implementing SQL Server Security 319

Overview of SQL Server Security 320

Lesson Summary 324

Comparison of SQL Server Security Modes 324

Lesson 3:Implementing Security in Microsoft Transaction Server 325

Understanding Roles and Security 325

Setting Package Properties 326

Using Programmatic Security 331

Lesson Summary 332

Lesson 4:Implementing COM Security Using DCOMCNFG 333

Overview of Distributed COM 334

Deploying a COM EXE 335

Creating Remote Server Files 336

Registering a Remote Component on a Client Computer 337

Practice:Registering a Component with Clireg32.exe 338

Lesson Summary 343

Summary 344

Lab:Using Programmatic Security in an MTS Component 345

Exercise 1:Adding a Role to your MTS Component 345

Exercise 2:Writing Code to Implement Programmatic Security 347

Review 349

Chapter 11:Debugging and Error Handling 351

About This Chapter 351

Before You Begin 351

Lesson 1:Handling Errors in an Application 352

Using Visual Basic Debugging Tools 352

Creating Error Handlers 356

Lesson Summary 360

Lesson 2:Testing and Debugging Middle-Tier Components 361

Testing Code Components 362

Debugging MTS Components 363

Handling Errors in MTS Components 364

MTS Component Debugging Limitations 367

Lesson Summary 369

Summary 370

Lab:Interactively Debugging an MTS Component 371

Exercise 1: 371

Review 375

Appendix A:Questions and Answers 377

Appendix B:Creating ActiveX Controls 393

Appendix C:Using the ADO Data Control 407

Appendix D:Creating Internet Applications 419

Appendix E:Preparing a Distributed Application for Deployment 437

Glossary 451

Index 473