Introduction to Windows Programming and MFC Training

Answers to Popular Questions:

 
Yes, this class can be tailored to meet your specific training needs.
Yes, we provide C++ consulting services.
Yes, group discounts are provided.

Course Description

 
This course teaches advanced programming techniques using the Win32 API and MFC. It is intended for experienced MFC developers who wish to better understand the fundamental architecture of Windows NT/2000 and Windows 95/98 and to utilize advanced programming techniques to create industrial strength applications. Module 1 begins with an overview of the Win32 architecture and the Win32 API. There is a discussion of the fundamentals of SDK Windows programming and MFC programming without the wizards. It then covers advanced MFC and Win32 programming topics including multi-threaded programming, DLLs, and interprocess communication. The fundamentals of COM are introduced, including the use of Visual C++ compiler support to create COM client programs. Module 2 covers database programming topics for C++ programmers. ODBC is covered, including a sample program showing ODBC programming at the API level. The MFC CDatabase, CRecordset and CRecordView classes are discussed in detail. There is coverage of parameterized queries and joins. Microsoft's Universal Data Access architecture is introduced, including a discussion of OLE DB. ActiveX Data Objects (ADO) programming in C++ is covered. An appendix covers programming with DAO. Module 3 is devoted to various advanced aspects of MFC programming, pertaining primarily to the user interface. There is extended treatment of the Win32 common controls, including the tree view control and image lists. Advanced features of document/view are covered, including multiple document types, multiple views, and multiple panes. Advanced menu techniques are covered. Dynamic toolbars and dialog bars are discussed. Advanced features of GDI are covered, including bitmaps, metafiles and printing. Use of the Windows system registry is covered. Extensive programming examples and exercises are provided using Visual C++ 6.0. Besides doing standalone exercises, during the course the student will develop several cumulative Windows applications. Self-extracting files are provided containing all the examples and laboratory exercises in the course.
Course Length: 5 Days
Course Tuition: $2090 (US)

Prerequisites

A basic knowledge of Windows programming using MFC and the Visual C++ development environment

Course Outline

 

Win32 Architecture and Programming
Windows Operating Systems
Dynamic Link Libraries
Win32 API
Kernel Objects
Win32 Memory Manageme

Win32 Programming
Win32 Program Flow
SDK Windows Programs
Console Programs
Windows Versions
Error Information
MFC Without the Wizards

Dynamic Link Libraries
Dynamic vs. Static Libraries
DLLs to Manage Resources
Explicit and Implicit Linking
Linking to C Language DLLs from C++ Programs
MFC Regular and Extension DLLs

Introduction to Threads Using MFC
Win32 Processes and Threads
MFC Thread Encapsulation
User Interface and Worker Threads
MFC Thread Synchronization
Thread Safety

Processes in Win32
Creating and Terminating Processes
Process Data Structures
Process Kernel Objects
Synchronization

Interprocess Data Communication
Interprocess Communciation in Win32
Memory-Mapped Files
WM_COPYDATA
Mailslots
Named Pipes

COM Fundamentals
Interfaces
Classes and Objects
Globally Unique Identifiers
Servers
Registration
Instantiating an Object
Object Lifetime and Interface Negotiation
Initializing COM
COM Client Programming Model

Appendix A. Visual C++ COM Support
Using Type Libraries with Import Directive
Namespaces
Smart Pointers
Error Handling
_bstr_t
 

Form Views and Data Entry
CFormView Class
Converting a Dialog to a Form View
Creating a Form View with AppWizard and ClassWizard
Control Variables in Dialog Data Exchange
Data Entry User Interface Paradigm

Introduction to ODBC
ODBC Architecture
Connecting to a Data Source
Executing SQL Statements
Retrieving Result Data

MFC Database Classes
CDatabase and CRecordset Classes
Record Field Exchange
Scrolling in a Recordset
Recordset Status
Choosing a Data Source at Runtime
MFC Specification of SELECT Statement
Edits, Adds and Deletes
CRecordView Class

More About ODBC
Using ODBC at the API Level
Parameterized Queries
Joins

ActiveX Data Objects
Universal Data Access
ODBC and OLE DB
ADO Object Model
Database Programming Using ADO

Appendix A. Data Access Objects

Windows Common Controls
Win32 Common Controls
MFC Common Control Classes
Progress, Slider and Animation Controls
Bitmaps and Image Lists
Tree View Control
List View Controls

Windows System Registry
System Registry
Win32 Registry API
Saving User Preferences in Registry

Advanced Document/View Architecture
Document Templates
Multiple Document Classes
Multiple View Classes
Splitter Windows and Multiple Panes

Advanced Menus and Toolbars
Dynamic Menus
Context Menus
Dynamic Toolbars
Dialog Bars
Advanced GDI

Coordinate Transformations
Scrolling
Printing
Metafiles
 

Course Directory [training on all levels]

Upcoming Classes