<?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[WM_CREATE]]></title><description><![CDATA[<p>Hy,</p>
<p>wann wird eigentlich immer WM_CREATE aufgerufen?<br />
Ich möchte mittels WH_CALLWNDPROC (systemweiter Hook) WM_CREATE abfangen.<br />
So wie ich WM_CREATE verstehe sollte doch beim Erstellen eines neuen Fensters dieses Event ausgelöst werden.<br />
Was ist mit den Fenstern , die zu diesem zeitpunkt bereits laufen? Zählen diese auch dazu? Zählt jeder Button usw auch als Fenster?(so war das glaub ich def.)<br />
Wie kann ich nur auf die Parent Windows zugreifen?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/205719/wm_create</link><generator>RSS for Node</generator><lastBuildDate>Sun, 26 Apr 2026 11:37:30 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/205719.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 17 Feb 2008 11:44:24 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 11:44:24 GMT]]></title><description><![CDATA[<p>Hy,</p>
<p>wann wird eigentlich immer WM_CREATE aufgerufen?<br />
Ich möchte mittels WH_CALLWNDPROC (systemweiter Hook) WM_CREATE abfangen.<br />
So wie ich WM_CREATE verstehe sollte doch beim Erstellen eines neuen Fensters dieses Event ausgelöst werden.<br />
Was ist mit den Fenstern , die zu diesem zeitpunkt bereits laufen? Zählen diese auch dazu? Zählt jeder Button usw auch als Fenster?(so war das glaub ich def.)<br />
Wie kann ich nur auf die Parent Windows zugreifen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457465</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457465</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Sun, 17 Feb 2008 11:44:24 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 12:15:08 GMT]]></title><description><![CDATA[<p>WM_CREATE ist eine der ersten Nachrichten, die an ein neu erstelltes Fenster gesendet wird, sozusagen als Antwort auf CreateWindow(). Daher kommt sie auch nur einmal an jedes Fenster.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457484</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457484</guid><dc:creator><![CDATA[Elektronix]]></dc:creator><pubDate>Sun, 17 Feb 2008 12:15:08 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 13:01:49 GMT]]></title><description><![CDATA[<p>wenn WM_CREATE nur einmal pro Fenster kommt, warum wird dieses Event immer (direkt nach dem Start der DLL) und permanent ohne aufzuhören ausgelöst? Hat jdm ne Idee?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457509</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457509</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Sun, 17 Feb 2008 13:01:49 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 16:50:53 GMT]]></title><description><![CDATA[<p>Fehler im DLL-Code? Zeig mal her...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457652</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457652</guid><dc:creator><![CDATA[Ahner]]></dc:creator><pubDate>Sun, 17 Feb 2008 16:50:53 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 17:36:09 GMT]]></title><description><![CDATA[<pre><code>LRESULT CALLBACK CallWndProc(int nCode, WPARAM wParam, LPARAM lParam) 
{
    //return CallNextHookEx(hhook, nCode, wParam, lParam);
	if (nCode != HC_ACTION) 
	{
		return CallNextHookEx(hhook, nCode, wParam, lParam);
	}

	switch(wParam)
	{
		case WM_CREATE: 
			cntWMCREATE++;
	break;
	}
}
</code></pre>
<p>Wenn ich einen Breakpunkt setze und anhalte liegt cntWMCREATE (linker section shared) etwa bei 13. Ich starte Programme und bleibe nicht am Breakpoint hängen. Starte dann den Explorer, und bleibe stehen. der Wert von cntWMCREATE liegt dann bei 100.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457675</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457675</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Sun, 17 Feb 2008 17:36:09 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 17:43:13 GMT]]></title><description><![CDATA[<p>Also, um Deinen Fehler einzukreisen, reicht Dein Code nicht aus.</p>
<p>Was für Variable ist cntWMCREAT ?<br />
Und wo wird sie initialisiert, also mit Wert 0 geladen?</p>
<p>Martin</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457680</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457680</guid><dc:creator><![CDATA[Mmacher]]></dc:creator><pubDate>Sun, 17 Feb 2008 17:43:13 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 18:17:10 GMT]]></title><description><![CDATA[<p>cntWMCREATE ist nur eine Zählvariable(int) und mit 0 init und liegt im shared Bereich!<br />
Der Aufruf funktioniert ja richtig ... nur stellt sich für mich die Frage , ob man die Hook-DLL´s auch richtig debuggen kann.</p>
<pre><code>DLL_EXPORT void SetHook(void)
{
	if (!bHooked)
	{
		//hhook		= SetWindowsHookEx(WH_MOUSE, (HOOKPROC)MouseProc, hInst, (DWORD)NULL);  
		hhook		= SetWindowsHookEx(WH_CALLWNDPROC, (HOOKPROC)CallWndProc, hInst, (DWORD)NULL); 
		bHooked		= true;	
	}
}
</code></pre>
<p>Der aufrufende Code (alles funzt hier prima)</p>
<p>Versucht zu debuggen hab ich mit VS6.0 und VS2005 (WinXP) .. beides male die selben Phänomene.</p>
<p>ich finde es merkwürdig, dass ich mit dem Explorer im Breakpoint stehen bleibe, sonst aber nicht...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457717</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457717</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Sun, 17 Feb 2008 18:17:10 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 19:26:37 GMT]]></title><description><![CDATA[<p>Hatte gemeint, Du zeigst mir die Definition Deiner Variable cntWMCREAT.</p>
<p>Hast Du mal mit static versucht? Also so:</p>
<pre><code class="language-cpp">static int cntWMCREAT=0;
</code></pre>
<p>Martin</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457768</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457768</guid><dc:creator><![CDATA[Mmacher]]></dc:creator><pubDate>Sun, 17 Feb 2008 19:26:37 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 19:42:58 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/16457">@Mmacher</a>:<br />
sorry , hatte ich missverstanden.<br />
Aber... macht keinen Unterschied(leider). Theoretisch sollte ich doch die Hook Dll debuggen können, oder? und genauso müsste doch die Funktion CallWndProc ständig aufgerufen werden, wenn ich einen Breakpoint auf <strong>if (nCode != HC_ACTION)</strong> setze , da ja noch nicht abgefragt wurde , um welche WM_xxx es sich handelt. Richtig?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457784</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457784</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Sun, 17 Feb 2008 19:42:58 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 21:42:03 GMT]]></title><description><![CDATA[<p>Ok, dann liegts nicht an der fehlerhaften Variablendefinition.</p>
<p>Eines vorneweg: Mit Hooks selbst habe ich mich noch nie beschäftigt, trotzdem versuche ichs Dir zu helfen (solange sich kein anderer dazu bereiterklärt <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f644.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--face_with_rolling_eyes"
      title=":rolling_eyes:"
      alt="🙄"
    /> .</p>
<p>Ohne in die Hook-Technik einzugehen: Bist Du Dir bewußt welches Fenster Du da &quot;anzapfst&quot;?<br />
Wenn Du z.B. ein Fenster von einem Dialog hookst, wirst Du sicher auch &quot;viele&quot; WM_CREATE's mitkriegen, denn jedes Button, Listbox, ja sogar Static-Control selbst bekommt je ein WM_CREATE, da Child-Fenster.<br />
Genauso verhält es sich mit der Menüleiste, jedes Popup-Menü ist ein Fenster usw.</p>
<p>Du kannst auch z.B. mit <em>IsParent()</em> und <em>IsChild()</em> prüfen, ob Du das richtige Fenster hast?</p>
<p>Hast Du auch mit anderen Tools gegengeprüft, z.B. mit WinSpy (es gibt natürlich auch andere), der Dir alle Informationen eines Fensters liefert.</p>
<p>Martin</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457848</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457848</guid><dc:creator><![CDATA[Mmacher]]></dc:creator><pubDate>Sun, 17 Feb 2008 21:42:03 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Sun, 17 Feb 2008 22:55:53 GMT]]></title><description><![CDATA[<p>wuTangl schrieb:</p>
<blockquote>
<pre><code>LRESULT CALLBACK CallWndProc(int nCode, WPARAM wParam, LPARAM lParam) 
{
    //return CallNextHookEx(hhook, nCode, wParam, lParam);
	if (nCode != HC_ACTION) 
	{
		return CallNextHookEx(hhook, nCode, wParam, lParam);
	}

	switch(wParam)
	{
		case WM_CREATE: 
			cntWMCREATE++;
	break;
	}
}
</code></pre>
</blockquote>
<p>Ich habe so eine WndProc noch nie gesehen. Aber WM_CREATE steht doch nicht in wParam. Das ist doch eine eigene Message. ich weis jetzt nicht ob nCode bei dir die Message ist, aber wenn dann musst du nCode auf WM_CREATE überprüfen.</p>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1457909</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1457909</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Sun, 17 Feb 2008 22:55:53 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:05:51 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/2620">@schirrmie</a>:<br />
[url]<a href="http://msdn2.microsoft.com/en-us/library/ms644975(VS.85).aspx" rel="nofollow">http://msdn2.microsoft.com/en-us/library/ms644975(VS.85).aspx</a><br />
[/url]<br />
Dort heißt es<br />
<strong>wParam</strong><br />
[in] Specifies whether the message was sent by the current thread. If the message was sent by the current thread, it is nonzero; otherwise, it is zero.</p>
<p>Ist da nicht die WindowsMessage mit gemeint?<br />
Da ich dort mittels breakpoint hingelange, denke ich mal, dass das richtig ist.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458000</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458000</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:05:51 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:13:27 GMT]]></title><description><![CDATA[<p>Ich weis ja nicht wie du das übersetzt <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /> aber bei mir heißt das soviel wie, &quot;wParam gibt an ob die Nachricht vom aktuellen Thread gesendet wurde, wenn ja ist wParam ungleich 0, ansonsten 0&quot;<br />
Und die Nachricht selber ist dann dein nCode. Also Prüfe nCode auf WM_CREATE.</p>
<p>du hast ja immer eine Nachricht (normalerseie message oder msg, bei dir nCode) und dazu zwei Datenfelder wParam und lParam wo zusatzinformationen zu dieser Nachricht gespeichert werden.</p>
<p>MfG schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458006</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458006</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:13:27 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:49:03 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/16457">@Mmacher</a>:</p>
<p>Ich will alle Fenster anzapfen (naja zumindest alle ParentFenster).<br />
Die Hook-Dll soll sich ja in jeden Prozess einhängen(deswegen gibt es ja auch einen gemeinsamen Variablen Bereich , sonst hätten die Variablen auch mit den ganzen Hook-Dll´s nichts miteinander zu tun)</p>
<p>Was mich verwundert: Ich debugge diese Hook-Dll und ich bleibe nur (immer wenn ich den Explorer starte im Breakpoint) hängen. Theoretisch erwarte ich , dass ich bei jedem WM_Create hängen bleibe.(auch bei allen child windows)</p>
<p>Kann ich in WinSpy die Einstellung vornehmen, dass ich das ganze system überwache? Oder nur ein Fenster?(was mir nichts nützne würde, da ich auf create untersuchen will)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458010</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458010</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:49:03 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:32:50 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/2620">@schirrmie</a>:<br />
Für mich heißt das: Falls eine Nachricht spezifiziert wurde(sprich !=0) sende die nachricht(in Form von WM_xxx)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458019</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458019</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:32:50 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:39:15 GMT]]></title><description><![CDATA[<p>Hmm ich weis nicht genau wie du das meinst aber wenn du vorher prüfen möchtest ob die Nachricht vom aktuellen Thread kommt dann mach es so (oder so ähnlich).</p>
<pre><code>LRESULT CALLBACK CallWndProc(int nCode, WPARAM wParam, LPARAM lParam) 
{
	...
	switch( nCode ) {
		case WM_CREATE: 
			if( wParam ) 
				cntWMCREATE++;
			break;
	}
}
</code></pre>
<p>Du darfst nicht wParam auf WM_CREATE prüfen!!!</p>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458025</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458025</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:39:15 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:45:34 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/2620">@schirrmie</a>:<br />
In der Doku steht(s.letzte URL):<br />
<strong>nCode</strong><br />
[in] Specifies whether the hook procedure must process the message. If nCode is HC_ACTION, the hook procedure must process the message. If nCode is less than zero, the hook procedure must pass the message to the CallNextHookEx function without further processing and must return the value returned by CallNextHookEx.</p>
<p>Da steht: Wenn nCode == AC_ACTION mache was , wenn nCode &lt; 0 rufe CallNextHookEx() auf. Das bedeutet doch im Umkehrschluss : Ich kann nCode gar nicht auf WM_Create untersuchen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458029</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458029</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:45:34 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:53:11 GMT]]></title><description><![CDATA[<p>Ja du hast recht tut mir leid, hab gerade mal in der MSDN geschaut. Aber eins steht fest du darfst trotzdem nicht wParam auf WM_CREATE überprüfen!!!</p>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458034</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458034</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:53:11 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:53:49 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/2620">@schirrmie</a>:<br />
Mal abgesehen vom switch():<br />
Müsste ich nicht immer in das if-statement(vor dem switch) via Breakpoint gelangen und das bei jeder WindowsMessage?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458035</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458035</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:53:49 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 09:57:24 GMT]]></title><description><![CDATA[<p>So jetzt habe ich weiter gelesen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /></p>
<blockquote>
<p>lParam<br />
Pointer to a CWPRETSTRUCT structure that contains details about the message.</p>
</blockquote>
<p>Also musst du lParam in eine CWPRETSTRUCT konvertieren und dann auf message in der struktur prüfen.</p>
<p>Jetzt sollten wir es haben <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f603.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--grinning_face_with_big_eyes"
      title=":D"
      alt="😃"
    /></p>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458037</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458037</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Mon, 18 Feb 2008 09:57:24 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 10:04:57 GMT]]></title><description><![CDATA[<p>wuTangl schrieb:</p>
<blockquote>
<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/2620">@schirrmie</a>:<br />
Mal abgesehen vom switch():<br />
Müsste ich nicht immer in das if-statement(vor dem switch) via Breakpoint gelangen und das bei jeder WindowsMessage?</p>
</blockquote>
<p>Probier deine Funktion mal so</p>
<pre><code>LRESULT CALLBACK CallWndProc(int nCode, WPARAM wParam, LPARAM lParam)
    if (nCode == HC_ACTION){
// Mache das was du willst
    }
    return CallNextHookEx(hhook, nCode, wParam, lParam) ;
    // Die Nachrichten an den nächsten Hook weiterreichen.
}
</code></pre>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458041</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458041</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Mon, 18 Feb 2008 10:04:57 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 10:07:56 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/2620">@schirrmie</a>:<br />
klingt gut.. ausprobiert .. ist es aber leider auch nicht!<br />
Es bleibt nicht mehr in WM_CREATE stehen!(wenn ich den Explorer starte) ...komisch</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458042</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458042</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 10:07:56 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 10:11:40 GMT]]></title><description><![CDATA[<p>Zeig mal wie dein Code dann jetzt aussieht!<br />
Hast du es mal mit einem anderen Programm (Notepad, Rechner) ausprobiert, wie dann das verhalten ist?</p>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458046</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458046</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Mon, 18 Feb 2008 10:11:40 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 10:31:18 GMT]]></title><description><![CDATA[<pre><code>LRESULT CALLBACK CallWndProc(int nCode, WPARAM wParam, LPARAM lParam) 
{
	if (nCode &lt; 0) 
	{
		return CallNextHookEx(hhook, nCode, wParam, lParam);
	}

	//
	UINT message = ((CWPSTRUCT*)lParam)-&gt;message;
	switch(message)
	{
		case WM_CREATE: 
			cntWMCREATE++;break;

		case WM_NCCREATE: 
			cntWMNCCREATE++; break;
			//überprüfe ob Window ein child oper parent Window is
	}
	return CallNextHookEx(hhook, nCode, wParam, lParam);

}
</code></pre>
<p>Ich glaube, dass es ein Problem des Debuggens ist. Es existiert ja zu jedem Prozess diese Hook-DLL. Und ich vermute stark, dass da was durcheinander läuft.<br />
Im erste Schritt geht es mir ja darum, zu verstehen, ob der Debugger richtig funzt oder nicht!<br />
Wie schon gesagt, ich komme nur in diese Funktion, wenn ich den Explorer starte oder was am eigentlichen Programm(welches die DLL koppelt und somit nicht systemweit anzusehen ist) mache. (Sprich mit der Mouse über den SystemTrayIcon)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458061</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458061</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 10:31:18 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 10:34:29 GMT]]></title><description><![CDATA[<p>Merkwürdig erscheint mir auch die Tatsache, dass wenn ich den Explorer starte, ich dann nur Message nr 992 --&gt;0x3E0 sehe .. welche es gar nicht gibt!<br />
vgl dazu<br />
[url]<br />
<a href="http://192.197.62.35/courses/comp638/src/week01/messages/wm.h" rel="nofollow">http://192.197.62.35/courses/comp638/src/week01/messages/wm.h</a><br />
[/url]</p>
<p>Ander Programme zeigen keine Auswirkung auf die Breakpoints</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458062</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458062</guid><dc:creator><![CDATA[wuTangl]]></dc:creator><pubDate>Mon, 18 Feb 2008 10:34:29 GMT</pubDate></item><item><title><![CDATA[Reply to WM_CREATE on Mon, 18 Feb 2008 11:43:22 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">#define WM_DDE_FIRST	    0x03E0
#define WM_DDE_INITIATE     (WM_DDE_FIRST)
#define WM_DDE_TERMINATE    (WM_DDE_FIRST+1)
#define WM_DDE_ADVISE	    (WM_DDE_FIRST+2)
#define WM_DDE_UNADVISE     (WM_DDE_FIRST+3)
#define WM_DDE_ACK	        (WM_DDE_FIRST+4)
#define WM_DDE_DATA	        (WM_DDE_FIRST+5)
#define WM_DDE_REQUEST	    (WM_DDE_FIRST+6)
#define WM_DDE_POKE	        (WM_DDE_FIRST+7)
#define WM_DDE_EXECUTE	    (WM_DDE_FIRST+8)
#define WM_DDE_LAST	        (WM_DDE_FIRST+8)
</code></pre>
<p>Verwende einfach mal Spy++ und Du kannst alle Nachrichten &quot;wirklich&quot; monitoren...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1458105</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1458105</guid><dc:creator><![CDATA[Martin Richter]]></dc:creator><pubDate>Mon, 18 Feb 2008 11:43:22 GMT</pubDate></item></channel></rss>