| Preface |
|
xxx | |
|
|
|
1 | (24) |
|
|
|
2 | (1) |
|
|
|
3 | (1) |
|
|
|
4 | (1) |
|
Evolution of Operating Systems |
|
|
4 | (1) |
|
Personal Computing, Distributed Computing, and Client/Server Computing |
|
|
5 | (1) |
|
Machine Languages, Assembly Languages, and High-Level Languages |
|
|
6 | (1) |
|
|
|
7 | (1) |
|
Other High-level Languages |
|
|
7 | (1) |
|
|
|
8 | (1) |
|
|
|
9 | (1) |
|
General Notes About Visual Basic and This Book |
|
|
10 | (1) |
|
|
|
11 | (14) |
|
Integrated Development Environment |
|
|
25 | (25) |
|
|
|
26 | (1) |
|
Integrated Development Environment Overview |
|
|
26 | (2) |
|
|
|
28 | (1) |
|
|
|
29 | (2) |
|
|
|
31 | (1) |
|
|
|
31 | (1) |
|
|
|
32 | (1) |
|
A Simple Program: Displaying a Line of Text |
|
|
33 | (17) |
|
Introduction to Visual Basic Programming |
|
|
50 | (38) |
|
|
|
51 | (1) |
|
Visual Programming and Event-Driven Programming |
|
|
51 | (1) |
|
A Simple Program: Printing a Line of Text on the Form |
|
|
52 | (8) |
|
Another Simple Program: Adding Integers |
|
|
60 | (4) |
|
|
|
64 | (1) |
|
|
|
64 | (2) |
|
|
|
66 | (3) |
|
Decision Making: Comparison Operators |
|
|
69 | (19) |
|
Control Structures: Part I |
|
|
88 | (41) |
|
|
|
89 | (1) |
|
|
|
89 | (1) |
|
|
|
90 | (1) |
|
Introduction to Control Structures |
|
|
91 | (2) |
|
If/Then Selection Structure |
|
|
93 | (1) |
|
If/Then/Else Selection Structure |
|
|
94 | (4) |
|
While Repetition Structure |
|
|
98 | (1) |
|
Do While Repetition Structure |
|
|
99 | (1) |
|
Do Until Repetition Structure |
|
|
100 | (1) |
|
Formulating Algorithms: Case Study 1 (Counter-Controlled Repetition) |
|
|
101 | (2) |
|
Formulating Algorithms with Top-down, Stepwise Refinement: Case Study 2 (Sentinel-Controlled Repetition) |
|
|
103 | (7) |
|
Formulating Algorithms with Top-down, Stepwise Refinement: Case Study 3 (Nested Control Structures) |
|
|
110 | (19) |
|
Control Structures: Part II |
|
|
129 | (48) |
|
|
|
130 | (1) |
|
Essentials of Counter-Controlled Repetition |
|
|
130 | (2) |
|
|
|
132 | (2) |
|
Examples Using the For/Next Repetition Structure |
|
|
134 | (6) |
|
Select Case Multiple-Selection Structure |
|
|
140 | (7) |
|
Do/Loop While Repetition Structure |
|
|
147 | (2) |
|
Do/Loop Until Repetition Structure |
|
|
149 | (2) |
|
Exit Do and Exit For Statements |
|
|
151 | (2) |
|
|
|
153 | (1) |
|
|
|
154 | (2) |
|
|
|
156 | (3) |
|
Structured Programming Summary |
|
|
159 | (5) |
|
|
|
164 | (13) |
|
Sub Procedures and Function Procedures |
|
|
177 | (70) |
|
|
|
178 | (1) |
|
|
|
178 | (2) |
|
|
|
180 | (6) |
|
|
|
186 | (4) |
|
Call-by-Value vs. Call-by-Reference |
|
|
190 | (4) |
|
Exit Sub and Exit Function |
|
|
194 | (3) |
|
|
|
197 | (1) |
|
|
|
198 | (3) |
|
|
|
201 | (7) |
|
Example: A Game of Chance |
|
|
208 | (6) |
|
Recursion and the Factorial Function |
|
|
214 | (3) |
|
Another Recursion Example: The Fibonacci Series |
|
|
217 | (3) |
|
|
|
220 | (1) |
|
|
|
221 | (2) |
|
|
|
223 | (2) |
|
Visual Basic Math Functions |
|
|
225 | (1) |
|
|
|
226 | (21) |
|
|
|
247 | (55) |
|
|
|
248 | (1) |
|
|
|
248 | (1) |
|
|
|
249 | (2) |
|
|
|
251 | (7) |
|
Passing Arrays to Procedures |
|
|
258 | (5) |
|
|
|
263 | (3) |
|
Searching Arrays: Linear Search and Binary Search |
|
|
266 | (5) |
|
|
|
271 | (3) |
|
|
|
274 | (4) |
|
|
|
278 | (7) |
|
Variable Arguments: ParamArray |
|
|
285 | (1) |
|
|
|
286 | (16) |
|
|
|
302 | (69) |
|
|
|
303 | (1) |
|
Fundamentals of Characters and Strings |
|
|
304 | (1) |
|
|
|
305 | (1) |
|
String Concatenation with & and + |
|
|
305 | (1) |
|
Comparing Character Strings |
|
|
306 | (3) |
|
|
|
309 | (2) |
|
Manipulating the Individual Characters in a String: Mid$ |
|
|
311 | (1) |
|
Left$, Right$, and InStr |
|
|
312 | (3) |
|
Searching for Substrings in Strings using InStr and InStrRev |
|
|
315 | (2) |
|
LTrim$, RTrim$ and Trim$ |
|
|
317 | (1) |
|
String$ and Spaces$ |
|
|
317 | (2) |
|
Replacing Substrings in a String with Function Replace |
|
|
319 | (1) |
|
Reversing Strings with Function StrReverse |
|
|
319 | (1) |
|
Converting Strings to Uppercase and Lowercase |
|
|
320 | (1) |
|
|
|
321 | (6) |
|
|
|
321 | (1) |
|
IsNumeric, Val and Str$ |
|
|
322 | (1) |
|
Hex$ and Oct$ |
|
|
323 | (1) |
|
The Type Conversion Functions |
|
|
324 | (3) |
|
|
|
327 | (13) |
|
Function Format$ and Named Numeric Formats |
|
|
327 | (2) |
|
Function Format$ and User-Defined Numeric Formats |
|
|
329 | (4) |
|
|
|
333 | (2) |
|
|
|
335 | (3) |
|
|
|
338 | (2) |
|
|
|
340 | (8) |
|
|
|
348 | (5) |
|
|
|
353 | (18) |
|
A Card Shuffling and Dealing Simulation |
|
|
356 | (15) |
|
|
|
371 | (37) |
|
|
|
372 | (1) |
|
|
|
372 | (2) |
|
|
|
374 | (8) |
|
|
|
382 | (5) |
|
Line Control and Shape Control |
|
|
387 | (3) |
|
|
|
390 | (8) |
|
|
|
398 | (2) |
|
|
|
400 | (8) |
|
Basic Graphical User Interface Concepts |
|
|
408 | (50) |
|
|
|
409 | (1) |
|
|
|
409 | (3) |
|
|
|
412 | (2) |
|
|
|
414 | (5) |
|
|
|
419 | (4) |
|
|
|
423 | (4) |
|
|
|
427 | (4) |
|
|
|
431 | (2) |
|
|
|
433 | (4) |
|
|
|
437 | (1) |
|
|
|
438 | (20) |
|
Advanced Graphical User Interface Concepts |
|
|
458 | (50) |
|
|
|
459 | (1) |
|
Multiple Document Interface (MDI) |
|
|
459 | (10) |
|
|
|
469 | (6) |
|
|
|
475 | (5) |
|
|
|
480 | (5) |
|
|
|
485 | (4) |
|
|
|
489 | (3) |
|
|
|
492 | (3) |
|
FlatScrollBar Control (Professional and Enterprise Editions) |
|
|
495 | (3) |
|
Native Code Compilation (Professional and Enterprise Editions) |
|
|
498 | (10) |
|
|
|
508 | (29) |
|
|
|
509 | (1) |
|
Changing the Shape of the Mouse Pointer |
|
|
509 | (3) |
|
|
|
512 | (3) |
|
|
|
515 | (2) |
|
|
|
517 | (3) |
|
|
|
520 | (6) |
|
|
|
526 | (3) |
|
|
|
529 | (8) |
|
Error Handling and Debugging |
|
|
537 | (41) |
|
|
|
538 | (1) |
|
When Error Handling Should Be Used |
|
|
539 | (1) |
|
A Simple Error-Handling Example: Divide by Zero |
|
|
539 | (3) |
|
Nested on Error Statements |
|
|
542 | (2) |
|
|
|
544 | (3) |
|
|
|
547 | (3) |
|
Error Handlers and the Call Stack |
|
|
550 | (5) |
|
|
|
555 | (1) |
|
Break Mode, the Immediate Window, and the Debug Object |
|
|
556 | (3) |
|
First Steps in Bug Prevention |
|
|
559 | (1) |
|
|
|
560 | (2) |
|
|
|
562 | (9) |
|
Debug Menu and Debug Tool Bar |
|
|
562 | (5) |
|
|
|
567 | (1) |
|
|
|
568 | (2) |
|
|
|
570 | (1) |
|
Debugger and Error Handlers |
|
|
571 | (7) |
|
Sequential File Processing |
|
|
578 | (37) |
|
|
|
579 | (1) |
|
DirListBox, FileListBox, and DriveListBox Controls |
|
|
579 | (4) |
|
|
|
583 | (1) |
|
|
|
584 | (15) |
|
Creating a Sequential Access File |
|
|
599 | (4) |
|
Reading Data from a Sequential Access File |
|
|
603 | (5) |
|
Updating Sequential Access Files |
|
|
608 | (7) |
|
Records and Random-Access Files |
|
|
615 | (30) |
|
|
|
616 | (1) |
|
|
|
616 | (1) |
|
Records as User-Defined Types |
|
|
617 | (2) |
|
User-Defined Type Definitions |
|
|
617 | (1) |
|
Manipulating Members of User-Defined Types |
|
|
618 | (1) |
|
Creating a Random-Access File |
|
|
619 | (5) |
|
Writing Data Randomly to a Random-Access File |
|
|
624 | (3) |
|
Reading Data Sequentially from a Random-Access File |
|
|
627 | (3) |
|
Reading Randomly from a Random-Access File |
|
|
630 | (3) |
|
Example: A Transaction Processing Program |
|
|
633 | (12) |
|
Object-Oriented Programming |
|
|
645 | (63) |
|
|
|
646 | (2) |
|
Data Abstraction and Information Hiding |
|
|
648 | (1) |
|
Implementing a Time Abstract Data Type with a Class |
|
|
649 | (4) |
|
|
|
653 | (7) |
|
Composition: Objects as Instance Variables of Other Classes |
|
|
660 | (6) |
|
Introduction to Object-Oriented Programming |
|
|
666 | (3) |
|
Software Engineering with Components |
|
|
669 | (1) |
|
Type Fields and Select Case Statements |
|
|
669 | (1) |
|
|
|
670 | (1) |
|
|
|
671 | (1) |
|
|
|
671 | (2) |
|
Case Study: IShape, CPoint, CCircle |
|
|
673 | (4) |
|
Case Study: A Payroll System Using Polymorphism |
|
|
677 | (7) |
|
Case Study: Polymorphic Processing of Shapes |
|
|
684 | (4) |
|
Simulating Implementation Inheritance with Interface Inheritance and Delegation |
|
|
688 | (6) |
|
|
|
694 | (1) |
|
|
|
695 | (13) |
|
|
|
708 | (58) |
|
|
|
709 | (1) |
|
|
|
709 | (4) |
|
|
|
713 | (2) |
|
ActiveX Control Lifetime and Events |
|
|
715 | (1) |
|
|
|
716 | (1) |
|
Creating an ActiveX Control That Contains Constituent Controls |
|
|
717 | (7) |
|
ActiveX Control Example: Clock Control |
|
|
724 | (7) |
|
ActiveX Control Interface Wizard |
|
|
731 | (10) |
|
Property Pages and the Property Page Wizard |
|
|
741 | (5) |
|
|
|
746 | (4) |
|
|
|
750 | (5) |
|
|
|
755 | (11) |
|
|
|
766 | (42) |
|
|
|
767 | (1) |
|
|
|
768 | (1) |
|
Advantages of Database Systems |
|
|
768 | (1) |
|
|
|
768 | (1) |
|
|
|
769 | (1) |
|
|
|
769 | (1) |
|
Relational Database Model |
|
|
769 | (2) |
|
|
|
769 | (2) |
|
Introducing the Microsoft ADO Data Control 6.0 and Microsoft DataGrid Control 6.0 |
|
|
771 | (5) |
|
Relational Database Overview: The Biblio.mdb Database |
|
|
776 | (3) |
|
Structured Query Language |
|
|
779 | (5) |
|
|
|
780 | (1) |
|
|
|
780 | (1) |
|
|
|
781 | (1) |
|
Using Inner Join to Merge Data from Multiple Tables |
|
|
782 | (1) |
|
All Titles Query from Biblio.mdb |
|
|
783 | (1) |
|
Revisiting the ADO Data Control and DataGrid Control |
|
|
784 | (4) |
|
Hierarchical FlexGrid Control |
|
|
788 | (1) |
|
DataList and DataCombo Controls |
|
|
789 | (7) |
|
Example: Using the DataCombo and DataList Controls |
|
|
790 | (4) |
|
Using the BoundColumn Property |
|
|
794 | (2) |
|
Using the Data Environment Designer |
|
|
796 | (5) |
|
Other Programmatic Capabilities of Recordsets |
|
|
801 | (1) |
|
|
|
801 | (7) |
|
Networking, the Internet and the World Wide Web |
|
|
808 | (52) |
|
|
|
809 | (1) |
|
Visual Basic Internet Controls |
|
|
810 | (1) |
|
|
|
811 | (5) |
|
Internet Transfer Control |
|
|
816 | (6) |
|
Hypertext Transfer Protocol (HTTP) Connections |
|
|
816 | (2) |
|
File Transfer Protocol (FTP) Connections |
|
|
818 | (4) |
|
Other Properties, Methods and Events of the Internet Transfer Control |
|
|
822 | (1) |
|
|
|
823 | (3) |
|
Establishing a Simple Server (Using TCP Protocol) |
|
|
823 | (2) |
|
Establishing a Simple Client (Using TCP Protocol) |
|
|
825 | (1) |
|
Example: Client/Server Interaction with the Winsock Control |
|
|
826 | (8) |
|
A Simple TCP-Based Server |
|
|
826 | (3) |
|
A Simple TCP-Based Client |
|
|
829 | (3) |
|
Outputs of the Client/Server Interactions |
|
|
832 | (2) |
|
Winsock Control and UDP-Based Client/Server Computing |
|
|
834 | (5) |
|
A Simple UDP-Based Server |
|
|
834 | (2) |
|
A Simple UDP-Based Client |
|
|
836 | (2) |
|
Outputs of the Client/Server Interactions |
|
|
838 | (1) |
|
Other Properties, Methods and Events of the Winsock Control |
|
|
839 | (1) |
|
Visual Basic Script (VBScript®): An Overview |
|
|
840 | (20) |
|
Multimedia: Images, Animation, Audio |
|
|
860 | (36) |
|
|
|
861 | (1) |
|
|
|
862 | (8) |
|
|
|
870 | (6) |
|
A Multimedia MCI Control CD Player |
|
|
872 | (2) |
|
A Multimedia MCI Control AVI File Player |
|
|
874 | (2) |
|
|
|
876 | (4) |
|
RealAudio ActiveX Control Library |
|
|
880 | (2) |
|
|
|
882 | (3) |
|
Microsoft ActiveMovie Control |
|
|
885 | (11) |
|
Data Structures, Collections and Dictionaries |
|
|
896 | (48) |
|
|
|
897 | (1) |
|
|
|
897 | (2) |
|
|
|
899 | (1) |
|
Dynamic Memory Allocation |
|
|
900 | (1) |
|
|
|
900 | (12) |
|
|
|
912 | (3) |
|
|
|
915 | (2) |
|
|
|
917 | (7) |
|
|
|
924 | (4) |
|
|
|
928 | (16) |
| Appendix A Operator Precedence Chart |
|
944 | (2) |
| Appendix B ANSI Character Set |
|
946 | (1) |
| Appendix C Visual Basic Internet and World Wide Web Resources |
|
947 | (6) |
|
C.1 Visual Basic Web Resources |
|
|
947 | (1) |
|
C.2 Microsoft Visual Basic Web Sites |
|
|
947 | (1) |
|
C.3 Visual Basic Resources |
|
|
948 | (1) |
|
|
|
949 | (1) |
|
C.5 Tutorials for Learning VB |
|
|
950 | (1) |
|
C.6 VB Newsgroups and Mailing lists |
|
|
950 | (1) |
|
C.7 VB Books and Magazines |
|
|
951 | (1) |
|
|
|
952 | (1) |
| Appendix D Number Systems |
|
953 | (14) |
|
|
|
954 | (3) |
|
D.2 Abbreviating Binary Numbers as Octal Numbers and Hexadecimal Numbers |
|
|
957 | (1) |
|
D.3 Converting Octal Numbers and Hexadecimal Numbers to Binary Numbers |
|
|
958 | (1) |
|
D.4 Converting from Binary, Octal, or Hexadecimal to Decimal |
|
|
958 | (1) |
|
D.5 Converting from Decimal to Binary, Octal, or Hexadecimal |
|
|
959 | (2) |
|
D.6 Negative Binary Numbers: Two's Complement Notation |
|
|
961 | (6) |
| Bibliography |
|
967 | (4) |
| Index |
|
971 | |