Let's debug the plug-in [PgTest] which was created in 'Making plug-ins'.
Start [Microsoft Visual C++ 2008 Express Edition].
Click the menu [File] >[Open] >[Project/Solution] to open the dialog [Open Project]. Select "PgTest.sln" and click the button [OK].
Set [Solution Configurations] in the toolbar to [Debug].
Click the right mouse button on '[Solution 'PgTest'] in [Solution Explorer
- PgTest] to show the shortcut menu.
Click the menu item [Build Solution] to start the building.
Confirm that the building process has been completed successfully.
To let Dynamic Draw recognize the plug-in, some information has to add
in the registory key.
If your account does not have administrator authority, you have to login with administrator authority.
Start [Command Prompt].
If you are using Windows Vista or later version, you have to proceed the following.
Click the right mouse button on '[Windows Start Button] >[All Programs] >[Accessories] >[Command Prompt]' to show the shortcut menu.
Click the menu item [Run as administrator].
Change the current directory to the directory '[PgTest]\Debug' in which
And enter the following.
By the proceedings above, the following dialog will be displayed.
It has been succeeded to let Dynamic Draw recognize the plug-in [PgTest].
Start Dynamic Draw by clicking the menu item in [Windows Start Button].
Show the property page [Plug-in] of the dialog [Environment setup].
Check [MyTest] and uncheck every checkbox else.
Exit Dynamic Draw.
Click the right mouse button on '[Solution 'PgTest'] >[PgTest] in [Solution
Explorer - PgTest] to show the shortcut menu.
Click the menu item [Properties].
The dialog [PgTest Property Pages] will be displayed.
Set the following settings.
Click the button [OK].
Open 'MpaCompo_0.cpp' and set a breakpoint at the beginning of the function "CA0::OnCommand".
Click the menu item [Debug] > [Start Debugging] to start the debugging process.
The debug symbolized Dynamic Draw will start.
Click the menu item [Plug-in] > [Component-0] > [About Component-0].
The function "CA0::OnCommand" will be called and it will break off the process at the breakpoint.
Check the Call Stack and confirm that the function "CA0::OnCommand"
has been called from the function "FCIMolipMain::OnCommand".
Double-click the "FCIMolipMain::OnCommand" line in the Call Stack.
The dialog [Find Source: molipexport.cpp] will be displayed because Visual
C++ isn't set the directory where the source code exists.
Set the directory "[TOP FOLDER]\DynamicDraw". It includes the source code file "molipexport.cpp" in which FCIMolipMain class is implemented.
Consequently the source code file "molipexport.cpp" is displayed.