<?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[Invalid Window Handle]]></title><description><![CDATA[<p>Hallo,</p>
<p>ich versuche einen Button in einem Childwindow zu erzeugen, leider bekomme ich ständig den Fehler: &quot;Invalid window Handle&quot; (Code 1400). Ich weiß allerdings nicht wieso.</p>
<p>Hie ist der Code wie ich den Button erzeugen möchte.</p>
<pre><code class="language-cpp">hVerticalRadio = CreateWindow(
				&quot;BUTTON&quot;, 
				&quot;OK&quot;, 
				WS_VISIBLE | WS_CHILD | BS_DEFPUSHBUTTON, 
				0, 0, 115, 16, 
				hThis, 
				NULL, 
				hThisInstance, 
				NULL);
</code></pre>
<p>hThis wurde vorher bereits erfolgreich mit folgendem Code erzeugt, ist allerdings noch nicht sichtbar.</p>
<pre><code class="language-cpp">wincl.hInstance = hThisInstance;
wincl.lpszClassName = szClassName;
wincl.lpfnWndProc = MsgProcedure;
wincl.style = CS_DBLCLKS;
wincl.hIcon = NULL;
wincl.hCursor = LoadCursor (NULL, IDC_ARROW);
wincl.lpszMenuName = NULL;
wincl.cbClsExtra = 0;
wincl.cbWndExtra = 0;
wincl.hbrBackground = (HBRUSH) GetStockObject(WHITE_BRUSH);

hThis = CreateWindowEx(	
			0,
			szClassName,
			NULL,
			WS_CHILD | WS_CLIPCHILDREN,
			x, y, width, height,
			hParent,
			NULL,
			hThisInstance,
			NULL);
</code></pre>
<p>Könnt Ihr mir sagen, warum ich immer diesen Fehler bekomme?</p>
<p>Danke für eure Hilfe</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/94433/invalid-window-handle</link><generator>RSS for Node</generator><lastBuildDate>Sun, 26 Apr 2026 00:59:51 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/94433.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 09 Dec 2004 08:14:01 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Invalid Window Handle on Thu, 09 Dec 2004 08:14:01 GMT]]></title><description><![CDATA[<p>Hallo,</p>
<p>ich versuche einen Button in einem Childwindow zu erzeugen, leider bekomme ich ständig den Fehler: &quot;Invalid window Handle&quot; (Code 1400). Ich weiß allerdings nicht wieso.</p>
<p>Hie ist der Code wie ich den Button erzeugen möchte.</p>
<pre><code class="language-cpp">hVerticalRadio = CreateWindow(
				&quot;BUTTON&quot;, 
				&quot;OK&quot;, 
				WS_VISIBLE | WS_CHILD | BS_DEFPUSHBUTTON, 
				0, 0, 115, 16, 
				hThis, 
				NULL, 
				hThisInstance, 
				NULL);
</code></pre>
<p>hThis wurde vorher bereits erfolgreich mit folgendem Code erzeugt, ist allerdings noch nicht sichtbar.</p>
<pre><code class="language-cpp">wincl.hInstance = hThisInstance;
wincl.lpszClassName = szClassName;
wincl.lpfnWndProc = MsgProcedure;
wincl.style = CS_DBLCLKS;
wincl.hIcon = NULL;
wincl.hCursor = LoadCursor (NULL, IDC_ARROW);
wincl.lpszMenuName = NULL;
wincl.cbClsExtra = 0;
wincl.cbWndExtra = 0;
wincl.hbrBackground = (HBRUSH) GetStockObject(WHITE_BRUSH);

hThis = CreateWindowEx(	
			0,
			szClassName,
			NULL,
			WS_CHILD | WS_CLIPCHILDREN,
			x, y, width, height,
			hParent,
			NULL,
			hThisInstance,
			NULL);
</code></pre>
<p>Könnt Ihr mir sagen, warum ich immer diesen Fehler bekomme?</p>
<p>Danke für eure Hilfe</p>
]]></description><link>https://www.c-plusplus.net/forum/post/669288</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/669288</guid><dc:creator><![CDATA[Hiiiilllffffeeee]]></dc:creator><pubDate>Thu, 09 Dec 2004 08:14:01 GMT</pubDate></item><item><title><![CDATA[Reply to Invalid Window Handle on Thu, 09 Dec 2004 08:25:03 GMT]]></title><description><![CDATA[<p>ist hThis wirklich ein gültiges Handle? Wird die Fensterklasse denn auch von Dir registriert?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/669295</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/669295</guid><dc:creator><![CDATA[Hepi]]></dc:creator><pubDate>Thu, 09 Dec 2004 08:25:03 GMT</pubDate></item><item><title><![CDATA[Reply to Invalid Window Handle on Thu, 09 Dec 2004 08:26:57 GMT]]></title><description><![CDATA[<p>Hepi schrieb:</p>
<blockquote>
<p>ist hThis wirklich ein gültiges Handle? Wird die Fensterklasse denn auch von Dir registriert?</p>
</blockquote>
<p>Ja die Fensterklasse wird registriert, ich habe RegisterClass nur vergessen mit zu kopieren.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/669296</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/669296</guid><dc:creator><![CDATA[Hiiiilllffffeeee]]></dc:creator><pubDate>Thu, 09 Dec 2004 08:26:57 GMT</pubDate></item><item><title><![CDATA[Reply to Invalid Window Handle on Thu, 09 Dec 2004 20:00:36 GMT]]></title><description><![CDATA[<p>Kommt der Fehler erst nach CreateWindow, oder schon nach CreateWindowEx?! Wird denn hThis später richtig angezeigt?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/669919</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/669919</guid><dc:creator><![CDATA[flenders]]></dc:creator><pubDate>Thu, 09 Dec 2004 20:00:36 GMT</pubDate></item><item><title><![CDATA[Reply to Invalid Window Handle on Thu, 09 Dec 2004 23:47:38 GMT]]></title><description><![CDATA[<p>Lass dir den Wert von hThis doch einfach mal ausgeben. Wie wird übrigens hParent initialisiert?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/670065</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/670065</guid><dc:creator><![CDATA[groovemaster]]></dc:creator><pubDate>Thu, 09 Dec 2004 23:47:38 GMT</pubDate></item></channel></rss>