Chapter 21: Tree and List Controls Visual C++ and MFC Fundamentals
- Import the cars from the Cars folder that accompany this book and change their IDs
accordingly to their file name. An example would be IDB_CIVIC for the civic.mdb - Design the rest of the dialog box with additional controls as follows:
Control ID Caption Other Properties
Picture 238 x 216
Static Text Make:
Edit Box IDC_MAKE
Static Text Model:
Edit Box IDC_MODEL
Static Text Year:
Edit Box IDC_YEAR Align Text: Right
Number: True
Static Text Doors:
Edit Box IDC_DOORS Align Text: Right
Number: True
Static Text Mileage:
Edit Box IDC_MILEAGE Align Text: Right
Number: True
Static Text Transmission:
Combo Box IDC_TRANSMISSION Type: Drop List
Data: Automatic;Manual
Group Box Options
Check Box IDC_AC Air Condition Left Text: True
Check Box IDC_AIR_BAGS Air Bags Left Text: True
Check Box IDC_CRUISE_CONTROL Cruise Control Left Text: True
Check Box IDC_CONVERTIBLE Convertible Left Text: True
Check Box IDC_CASSETTE Cassette Left Text: True
Check Box IDC_CD_PLAYER CD Player Left Text: True
Picture IDC_PICTURE Type: Bitmap
Image: IDB_ESCORT
Center Image: True
Dimensions: 210x 86
- Add a variable to each non-static control as follows:
ID Value Variable^ Control Variable^
Type Name Type Name
IDC_MAKE CString m_Make
IDC_MODEL CString m_Model