Vortex86DX-MSJK Windows Embedded CE 6.0 R3 Jump Start Rev 2.2
Page 72 of 144
After the project wizard step is completed, the initial
VS2008_Win32_HelloWorld
project files are
created in the following folder:
C:\Lab\VS2008_Win32_HelloWorld
Add Codes and Build the Application Project
With the
VS2008_Win32_HelloWorld
project active, the VS2008 IDE should look similar to the IDE
as shown in Figure 69.
Fig. 69 -
VS2008 IDE with VS2008_Win32_HelloWorld project active
Work through the following steps to add some code to the
VS2008_Win32_HelloWorld
project:
•
From the VS2008 IDE’s Solution Explorer tab, double click on the
VS2008_Win32_HelloWorld.cpp
file, in the
\Source Files
folder to view and edit the codes
in the code editor window.
•
Replace the codes in the “
case WM_PAINT:”
statement section with the following codes, as
shown in Figure 70.
Case WM_PAINT:
//
RECT rect;
GetClientRect (hWnd, &rect);
hdc = BeginPaint(hWnd, &ps);
DrawText(hdc, TEXT(
"Hello World Win32 Native Application!"
),-1, &rect,
DT_CENTER|DT_VCENTER|DT_SINGLELINE);
EndPaint(hWnd, &ps);
break
;