How to start debugging Visual C++ project
To start debugging Visual C++ project
Step a: Build>Start Debug
Go= simply executes a program up to the breakpoint where execution will halt.
Step info= execute your program one statement at a time.
To start debugging Visual C++ project
Step a: Build>Start Debug
Go= simply executes a program up to the breakpoint where execution will halt.
Step info= execute your program one statement at a time.
To use Escape Sequences:
Code | Meaning Of Code |
\a | Audible bell |
\b | Backspace |
\f | Formfeed |
\n | Newline |
\r | Carriage return |
\t | Horizontal tab |
\\ | Backslash character |
\’ | Single quote character |
\" | Double quote character |
\0 | Null ASCII 0 |
To set the project option
Step a: Project>Setting
To set option in Visual C++
Step a: Tools>Option
To build the Project
Step a: Click the
This will begin building the Visual C++ project.
To add a source file to a Project
Step a: Right click the mouse key select insert File into Project
To enter the c++ source file
Step a: File>New
Step b: Select the C++ source file in the Files Tap
Step c: Enter the code
Tto process Debug or Release Version of your Program
These option determine how your source code is to be processed during the compile and link stages
To select from Dockable Toolbars
Click on the icons as shown below to do respective file handling functions.
To select Toolbar options
Options with the check icons were selected.
To view results in Build, Debug, Find in Files1 and Files2
Select from the tabs as shown below to view the results.
To use The ClassView ResourceView and FileView:
Click on the tabs as shown to go to ResourceView or FileView.
To select the Project Workspace dialog box
Click on the folder to view resources.
To select from the Control ToolBar
To select from The Menu Bar
Using the IDE
To change the Font size
Step a: Adding the Group box in the dialog box
Step b: Adding the Radio button in the dialog box checked in General tab
Step c: Attaching a variable to the Radio Buttons
Step d: View>Class Wizard
Step e: Member Variables Class name: CFontDlg Control ID: IDC_RADIO1
Step f: Click ’Add Variables’ button
Step g: Initializing the Radio Buttons
Step h: View>Class Wizard
Step i: Message Maps Class name: CFontDlg Object ID:CFontDlg Message: WM_INITDIALOG
Step j: Click ‘Edit Code’ button
Step k: View>Class Wizard
Step l: Message Maps Class name: CFontDlg Object ID: IDC_RADIO1 Message:BN_CLICKED
Step m: Click ‘Add Function’ and Click ‘Edit Code’
To display the words in the dialog box
Step a: Make the MFCAppWizard(exe)
Step b: Make the push button and edit box into the dialog box
Step c: Attaching a Variable the edit box
Step d: View>Class Wizard
Step e: Member Variables tab Class name:CfontDlg Control ID:IDC_EDIT
Step f: Click ‘Add Variable’ Button Member Variable name: m_Data Category: Value Variable types: CString
Step g: Click ‘OK’ button
Step h: Attaching Code to the EN_CHANGE Event
Step i: View>Class Wizard
Step j: Message Maps Class name: CfontDlg Object ID: IDC_EDIT1 Message:EN_CHANGE
Step k: Click ‘Add Function’ button and Click ‘Edit Code’ button
Step l: Enter Code
Step m: attaching code to the WM_PAINT
Step n View>Class Wizard
Step o: Message Maps Class name: CFontDlg Object ID: CFontDlg Message: WM_PAINT
Step p: Click ‘Edit Code’ button
Enter the Code
To associate the new dialog box with a class
Step a: View>Class Wizard
Step b: They were display the Adding a Class message click ‘OK’ button
Step c: They were display the New Class message box enter the Name
Step d: Make sure the Base class list box is set to Cdialog
To insert a new dialog box in the project
Step a: Make the MFCAppWizard(exe)
Step b: Right click the dialog box Workspace Window
Step c: Select the Insert Dialog in the menu
To make the Yes and No message boxes
Step a: Make a Push Button in the dialog box
Step c: View>ClassWizard
Step d: Class Name: CprojectDlg Object ID:IDC_BUTTON4 Message:BN_CLICKED
Step e: Click the ‘Add Function’ button
Step f: Click the ‘Edit Code’ Button
Step g: Enter Code
To make the Retry and Cancel message boxes
Step a: Make a Push Button in the dialog box
Step c: View>ClassWizard
Step d: Class Name: CprojectDlg Object ID:IDC_BUTTON3 Message:BN_CLICKED
Step e: Click the ‘Add Function’ button
Step f: Click the ‘Edit Code’ Button
Step e:nter the code
To make the Yes, No and Cancel message boxes...
Step a: Make a Push Button in the dialog box
Step c: View>ClassWizard
Step d: Class Name: CprojectDlg Object ID:IDC_BUTTON2 Message:BN_CLICKED
Step e: Click the ‘Add Function’ button
Step f: Click the ‘Edit Code’ Button
Step g: Enter Code
To make the OK and CANCEL message boxes...
Step a: Make the MFCAppWizard(exe)
Step b: Make a Push Button in the dialog box
Step c: View>ClassWizard
Step d: Class Name: CprojectDlg Object ID:IDC_BUTTON1 Message:BN_CLICKED
Step e: Click the ‘Add Function’ button
Step f: Click the ‘Edit Code’ Button
Step g: Enter Code
To make the menu
Step a: go to Insert>Resource
Step b: select the menu click the ‘New’ button
Step c: Right the mouse button select properties
Step d: Enter the Caption
To Control the keyboard
Step a: Open the Class Wizard
Step b: Select the Following event Class names: CCanDlg Object ID:CCanDlg and Message:WM_KEYDOWN
Step c: Click ‘Add Function’ button
Step d: Click ‘Edit Code’ button
Step e: Enter the code
To control the mouse
Step a: Open the Class Wizard
Step b: Select the Following event Class names: CCanDlg Object ID:CCanDlg and Message:WM_MOUSEMOVE
Step c: Click ‘Add Function’ button
Step d: Click ‘Edit Code’ button
Step e: enter the code