<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[WinAPI Problem mit Visual C++ Book Edition]]></title><description><![CDATA[<p>Hallo</p>
<p>Ich habe vor ein paar Tagen mit WinAPI angefangen. Habe mir mal ein Beispiel gesucht:</p>
<p>#include &lt;windows.h&gt;</p>
<p>LRESULT CALLBACK WndProc (HWND, UINT, WPARAM, LPARAM);</p>
<p>int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,<br />
PSTR szCmdLine, int iCmdShow)<br />
{<br />
static char szAppName[] = &quot;Name&quot; ;<br />
HWND hwnd ;<br />
MSG msg ;<br />
WNDCLASSEX wndclass ;</p>
<p>wndclass.cbSize = sizeof (wndclass) ;<br />
wndclass.style = CS_HREDRAW | CS_VREDRAW ;<br />
wndclass.lpfnWndProc = WndProc ;<br />
wndclass.cbClsExtra = 0 ;<br />
wndclass.cbWndExtra = 0 ;<br />
wndclass.hInstance = hInstance ;<br />
wndclass.hIcon = LoadIcon (NULL, IDI_APPLICATION) ;<br />
wndclass.hCursor = LoadCursor (NULL, IDC_ARROW) ;<br />
wndclass.hbrBackground = (HBRUSH) GetStockObject (WHITE_BRUSH) ;<br />
wndclass.lpszMenuName = NULL ;<br />
wndclass.lpszClassName = szAppName ;<br />
wndclass.hIconSm = LoadIcon (NULL, IDI_APPLICATION) ;</p>
<p>RegisterClassEx (&amp;wndclass) ;</p>
<p>hwnd = CreateWindow (szAppName, &quot;Fenstername&quot;, WS_OVERLAPPEDWINDOW,<br />
CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,<br />
NULL, NULL, hInstance, NULL) ;</p>
<p>ShowWindow (hwnd, iCmdShow) ;<br />
UpdateWindow (hwnd) ;</p>
<p>while (GetMessage (&amp;msg, NULL, 0, 0))<br />
{<br />
TranslateMessage (&amp;msg) ;<br />
DispatchMessage (&amp;msg) ;<br />
}<br />
return msg.wParam ;<br />
}</p>
<p>LRESULT CALLBACK WndProc (HWND hwnd, UINT iMsg, WPARAM wParam, LPARAM lParam)<br />
{<br />
switch (iMsg)<br />
{<br />
case WM_CREATE :</p>
<p>return 0 ;</p>
<p>case WM_PAINT :</p>
<p>return 0 ;</p>
<p>case WM_DESTROY :<br />
PostQuitMessage (0) ;<br />
return 0 ;<br />
}</p>
<p>return DefWindowProc (hwnd, iMsg, wParam, lParam) ;<br />
}</p>
<p>Aber immer, wenn ich es compilieren will, kommt &quot;fatal error C1010: Unerwartetes Dateiende waehrend der Suche nach der Direktive fuer die vorkompilierte Header-Datei Fehler beim Ausführen von cl.exe.&quot; Das Selbe kommt auch bei ähnlichen Beispielen...</p>
<p>Weis jemand, was ich falsch mache?</p>
<p>Würde mich über eine schnelle Antowrt freuen</p>
<p>MfG Eddi</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/169962/winapi-problem-mit-visual-c-book-edition</link><generator>RSS for Node</generator><lastBuildDate>Wed, 15 Jul 2026 16:46:35 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/169962.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 10 Jan 2007 14:31:39 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to WinAPI Problem mit Visual C++ Book Edition on Wed, 10 Jan 2007 14:31:39 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>Ich habe vor ein paar Tagen mit WinAPI angefangen. Habe mir mal ein Beispiel gesucht:</p>
<p>#include &lt;windows.h&gt;</p>
<p>LRESULT CALLBACK WndProc (HWND, UINT, WPARAM, LPARAM);</p>
<p>int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance,<br />
PSTR szCmdLine, int iCmdShow)<br />
{<br />
static char szAppName[] = &quot;Name&quot; ;<br />
HWND hwnd ;<br />
MSG msg ;<br />
WNDCLASSEX wndclass ;</p>
<p>wndclass.cbSize = sizeof (wndclass) ;<br />
wndclass.style = CS_HREDRAW | CS_VREDRAW ;<br />
wndclass.lpfnWndProc = WndProc ;<br />
wndclass.cbClsExtra = 0 ;<br />
wndclass.cbWndExtra = 0 ;<br />
wndclass.hInstance = hInstance ;<br />
wndclass.hIcon = LoadIcon (NULL, IDI_APPLICATION) ;<br />
wndclass.hCursor = LoadCursor (NULL, IDC_ARROW) ;<br />
wndclass.hbrBackground = (HBRUSH) GetStockObject (WHITE_BRUSH) ;<br />
wndclass.lpszMenuName = NULL ;<br />
wndclass.lpszClassName = szAppName ;<br />
wndclass.hIconSm = LoadIcon (NULL, IDI_APPLICATION) ;</p>
<p>RegisterClassEx (&amp;wndclass) ;</p>
<p>hwnd = CreateWindow (szAppName, &quot;Fenstername&quot;, WS_OVERLAPPEDWINDOW,<br />
CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,<br />
NULL, NULL, hInstance, NULL) ;</p>
<p>ShowWindow (hwnd, iCmdShow) ;<br />
UpdateWindow (hwnd) ;</p>
<p>while (GetMessage (&amp;msg, NULL, 0, 0))<br />
{<br />
TranslateMessage (&amp;msg) ;<br />
DispatchMessage (&amp;msg) ;<br />
}<br />
return msg.wParam ;<br />
}</p>
<p>LRESULT CALLBACK WndProc (HWND hwnd, UINT iMsg, WPARAM wParam, LPARAM lParam)<br />
{<br />
switch (iMsg)<br />
{<br />
case WM_CREATE :</p>
<p>return 0 ;</p>
<p>case WM_PAINT :</p>
<p>return 0 ;</p>
<p>case WM_DESTROY :<br />
PostQuitMessage (0) ;<br />
return 0 ;<br />
}</p>
<p>return DefWindowProc (hwnd, iMsg, wParam, lParam) ;<br />
}</p>
<p>Aber immer, wenn ich es compilieren will, kommt &quot;fatal error C1010: Unerwartetes Dateiende waehrend der Suche nach der Direktive fuer die vorkompilierte Header-Datei Fehler beim Ausführen von cl.exe.&quot; Das Selbe kommt auch bei ähnlichen Beispielen...</p>
<p>Weis jemand, was ich falsch mache?</p>
<p>Würde mich über eine schnelle Antowrt freuen</p>
<p>MfG Eddi</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1207166</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1207166</guid><dc:creator><![CDATA[Eddi0406]]></dc:creator><pubDate>Wed, 10 Jan 2007 14:31:39 GMT</pubDate></item><item><title><![CDATA[Reply to WinAPI Problem mit Visual C++ Book Edition on Wed, 10 Jan 2007 14:48:10 GMT]]></title><description><![CDATA[<p>deaktivier mal &quot;vorkompilierte header&quot; in den projektoptionen</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1207178</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1207178</guid><dc:creator><![CDATA[--------]]></dc:creator><pubDate>Wed, 10 Jan 2007 14:48:10 GMT</pubDate></item><item><title><![CDATA[Reply to WinAPI Problem mit Visual C++ Book Edition on Wed, 10 Jan 2007 15:04:45 GMT]]></title><description><![CDATA[<p>Kannst du mir sagen, wie man das macht? Finds einfach ned...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1207185</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1207185</guid><dc:creator><![CDATA[Eddi0406]]></dc:creator><pubDate>Wed, 10 Jan 2007 15:04:45 GMT</pubDate></item><item><title><![CDATA[Reply to WinAPI Problem mit Visual C++ Book Edition on Wed, 10 Jan 2007 15:11:21 GMT]]></title><description><![CDATA[<p>das beste waere wenn du direkt am start wenn du das projekt erstellst den precompiled header deaktivierst {o;</p>
<p>VS2005 Prof<br />
Project-&gt;Properties-&gt;Configuration Properties-&gt;C/C++-&gt;Precompiled Headers-&gt;Create/Use Precompiled Header auf &quot;Not using precompiled header&quot; stellen</p>
<p>in VS2003 nachzuschaun hab ich grad keine lust zu #gg</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1207189</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1207189</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Wed, 10 Jan 2007 15:11:21 GMT</pubDate></item><item><title><![CDATA[Reply to WinAPI Problem mit Visual C++ Book Edition on Wed, 10 Jan 2007 15:25:09 GMT]]></title><description><![CDATA[<p>Ich finds immer noch nicht. Sicher, dass es das bei der 2006er Book Edition auch gibt?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1207195</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1207195</guid><dc:creator><![CDATA[Eddi0406]]></dc:creator><pubDate>Wed, 10 Jan 2007 15:25:09 GMT</pubDate></item><item><title><![CDATA[Reply to WinAPI Problem mit Visual C++ Book Edition on Wed, 10 Jan 2007 15:37:52 GMT]]></title><description><![CDATA[<p>Ok Ich habs (war ziemlich gut versteckt) und es hat auch funktioniert. Danke für eure Hilfe</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1207200</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1207200</guid><dc:creator><![CDATA[Eddi0406]]></dc:creator><pubDate>Wed, 10 Jan 2007 15:37:52 GMT</pubDate></item></channel></rss>