<?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[2tes Fenster???]]></title><description><![CDATA[<p>Hallo allereseits!<br />
Da ich erst vor kurzem mit der Winapi programmierung begonnen habe, habe ich eine Frage die ihr mir hoffentlich beantworten könnts.<br />
Ich habe ein 2Fenster mit dem Ressourcen Editor erstellt.<br />
Nun habe ich in das Hauptfenster einen Button(ebnfalls über Ressourcen Editor) eingefügt!<br />
Jetzt würde ich gerne, dass das 2Fenster aufgeht wenn der Button geklickt wurde!</p>
<pre><code class="language-cpp">BOOL CALLBACK MainProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam)
{
   switch(Message)
   {
      case WM_COMMAND: 
	switch(LOWORD(wParam))//Was haben wir geklickt??
	{
		case Testbutton:
                           //Hier würde ich gerne mein Fenster aufrufen
        }

  }
}
</code></pre>
<p>Falls es wichtig ist:<br />
Ich habe im 2ten Fenster nur einen Button welches das Fenster wieder schließt!</p>
<p>Ich DANKE euch schon im Vorraus!</p>
<p>P.s: Ich habe bereits im Forum gesucht aber nichts gefunden was mir helfen würde!</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/209088/2tes-fenster</link><generator>RSS for Node</generator><lastBuildDate>Fri, 24 Apr 2026 10:58:16 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/209088.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 26 Mar 2008 15:04:50 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:04:50 GMT]]></title><description><![CDATA[<p>Hallo allereseits!<br />
Da ich erst vor kurzem mit der Winapi programmierung begonnen habe, habe ich eine Frage die ihr mir hoffentlich beantworten könnts.<br />
Ich habe ein 2Fenster mit dem Ressourcen Editor erstellt.<br />
Nun habe ich in das Hauptfenster einen Button(ebnfalls über Ressourcen Editor) eingefügt!<br />
Jetzt würde ich gerne, dass das 2Fenster aufgeht wenn der Button geklickt wurde!</p>
<pre><code class="language-cpp">BOOL CALLBACK MainProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lParam)
{
   switch(Message)
   {
      case WM_COMMAND: 
	switch(LOWORD(wParam))//Was haben wir geklickt??
	{
		case Testbutton:
                           //Hier würde ich gerne mein Fenster aufrufen
        }

  }
}
</code></pre>
<p>Falls es wichtig ist:<br />
Ich habe im 2ten Fenster nur einen Button welches das Fenster wieder schließt!</p>
<p>Ich DANKE euch schon im Vorraus!</p>
<p>P.s: Ich habe bereits im Forum gesucht aber nichts gefunden was mir helfen würde!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480697</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480697</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:04:50 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:12:50 GMT]]></title><description><![CDATA[<p>Was ist jetzt Dein Problem?</p>
<p>Wenn ich dich richtig verstanden habe, fehlt Dir das:</p>
<p>Zum Öffnen des Fensters</p>
<pre><code>hChild = CreateWindow bzw. CreateWindowEx..
</code></pre>
<p>Zum schließen:</p>
<pre><code>DestroyWindow(hChild)
</code></pre>
<p>Allerdings braucht das ChildWindow auch eine Callback-Funktion, in dem die Nachrichten des Buttons verarbeitet werden.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480703</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480703</guid><dc:creator><![CDATA[Elektronix]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:12:50 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:13:26 GMT]]></title><description><![CDATA[<p>Ich weiß nicht wie ich das neue Fenster aufrufe...</p>
<p>Ich schaue mir jetzt die 2 Befehle an...</p>
<p>Hast du vll auch ein kleines BSP wo diese 2 Befehle verwendet werden?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480706</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480706</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:13:26 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:23:47 GMT]]></title><description><![CDATA[<p>Z. B. da: <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/27a1.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--right_arrow"
      title=":arrow_right:"
      alt="➡"
    /> <a href="http://www.win-api.de/tutorials.php?tutid=12" rel="nofollow">http://www.win-api.de/tutorials.php?tutid=12</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480721</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480721</guid><dc:creator><![CDATA[Elektronix]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:23:47 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:27:04 GMT]]></title><description><![CDATA[<p>Was ich da aber nicht ganz herauslesen konnte wie rufe ich das Fenster auf was ich bereits mit dem Ressourcen Editor erstellt habe??<br />
Da steht nur wie ich ein neues Fenster erstellen kann..</p>
<p>Ich würde aber gerne nur das Fenster aufrufen was ich bereits erstellt habe...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480724</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480724</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:27:04 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:34:36 GMT]]></title><description><![CDATA[<p>Zum Umgang mit Ressourcen: <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/27a1.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--right_arrow"
      title=":arrow_right:"
      alt="➡"
    /> <a href="http://pronix.linuxdelta.de/C/win32/win32_5.shtml" rel="nofollow">http://pronix.linuxdelta.de/C/win32/win32_5.shtml</a></p>
<p>Das Beispiel steht für modale Dialoge (mit &quot;DialogBox()... EndDialog()). Moduslose Dialoge rufst Du mit CreateDialog() auf und gibst die Fenster-ID in den Parametern an. Beendet wird der dann mit DestroyWindow().</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480729</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480729</guid><dc:creator><![CDATA[Elektronix]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:34:36 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:35:51 GMT]]></title><description><![CDATA[<p>Hmmm...Danke aber da steht nichts von neuem Fenster aufrufen??<br />
Weist du wie es funkt??Es wäre sehr Hilfreich wenn du mir den Befehl sagen würdest...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480732</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480732</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:35:51 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:59:37 GMT]]></title><description><![CDATA[<p>WINAPI nooooobie schrieb:</p>
<blockquote>
<p>Hmmm...Danke aber da steht nichts von neuem Fenster aufrufen??<br />
Weist du wie es funkt??Es wäre sehr Hilfreich wenn du mir den Befehl sagen würdest...</p>
</blockquote>
<p>Wenn Du eine Fensterklasse neu erstellst (mit Ressourcen-Editor oder als Standard-Fenster), brauchst Du immer eine Callback-Funktion dazu. Die Befehle dazu sind CreateWindow, CreateWindowEx, CreateDialog oder DialogBox. Die letzten bei den nutzen intern auch die CreateWindowEx-Funktion.</p>
<p>Borland-Hilfe schrieb:</p>
<blockquote>
<p>The CreateDialog macro creates a modeless dialog box from a dialog box<br />
template resource. The CreateDialog macro uses the CreateDialogParam function.</p>
<p>HWND CreateDialog(</p>
<p>HINSTANCE hInstance, // handle to application instance<br />
LPCTSTR lpTemplate, // identifies dialog box template name<br />
HWND hWndParent, // handle to owner window<br />
DLGPROC lpDialogFunc // pointer to dialog box procedure<br />
);</p>
<p>Parameters</p>
<p>hInstance<br />
Identifies an instance of the module whose executable file contains the dialog box template.</p>
<p>lpTemplate<br />
Identifies the dialog box template. This parameter is either the pointer to a<br />
null-terminated character string that specifies the name of the dialog box<br />
template or an integer value that specifies the resource identifier of the<br />
dialog box template. If the parameter specifies a resource identifier, its<br />
high-order word must be zero and its low-order word must contain the identifier.<br />
You can use the MAKEINTRESOURCE macro to create this value.</p>
<p>hWndParent<br />
Identifies the window that owns the dialog box.</p>
<p>lpDialogFunc<br />
Points to the dialog box procedure. For more information about the dialog box procedure, see DialogProc.</p>
</blockquote>
<p>Jeder Dialog und jeder Button ist nichts anderes als ein Fenster und wird auch so aufgerufen. Schau Dir die Window-Styles an.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480747</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480747</guid><dc:creator><![CDATA[Elektronix]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:59:37 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 15:59:48 GMT]]></title><description><![CDATA[<p>Habe das jetzt so gemacht aber es funktioniert nicht!</p>
<p>Callback vom Neuen Fenster:</p>
<pre><code class="language-cpp">BOOL CALLBACK Test(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam){

    switch (message)
	{
     case WM_INITDIALOG:
		{
			return TRUE;
		}
    }
}
</code></pre>
<pre><code class="language-cpp">case Testbutton:
CreateDialog(hInstance,MAKEINTRESOURCE(IDD_TesDialog),hwnd,Test);
</code></pre>
<p>Wieso das?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1480752</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480752</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 15:59:48 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 17:03:10 GMT]]></title><description><![CDATA[<p>&quot;funktioniert nicht&quot; gibts hier nicht.<br />
ohne präzisierung des fehlers gehts nicht.</p>
<p>da fehlt zudem ein</p>
<pre><code class="language-cpp">return FALSE;
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1480831</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1480831</guid><dc:creator><![CDATA[Xantus]]></dc:creator><pubDate>Wed, 26 Mar 2008 17:03:10 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 21:02:33 GMT]]></title><description><![CDATA[<p>Naja ich klicke zwar auf den Button aber es erscheint kein neues Fenster...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481005</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481005</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 21:02:33 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:28:16 GMT]]></title><description><![CDATA[<p>Hoi,</p>
<p>1. Bist Du Dir sicher, dass Dein Button auch mit der symbolischen ID 'Testbutton' versehen ist?<br />
2. Welchen Wert bzw. wie initialisierst/definierst Du 'hInstance'?<br />
3. Deine Dialog-Funktion 'Test' ist falsch, siehe MSDN bzw. Hinweis von Xantus.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481050</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481050</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:28:16 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:34:38 GMT]]></title><description><![CDATA[<p>ZU:</p>
<ol>
<li>Ja bin mir sicher habe es nochmals kontrolliert!</li>
<li>HINSTANCE hInstance;<br />
3)hwndGoto = CreateDialog(hinst,<br />
MAKEINTRESOURCE(DLG_GOTO),<br />
hwnd, (DLGPROC) GoToProc);<br />
ShowWindow(hwndGoto, SW_SHOW); ==&gt;Habe es auch so probiert!Kommt aber trotzdem kein Fenster!</li>
</ol>
]]></description><link>https://www.c-plusplus.net/forum/post/1481053</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481053</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:34:38 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:40:25 GMT]]></title><description><![CDATA[<p>lol, also hat hInstance keinen definierten Anfangswert <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="😃"
    /> - gute Arbeit^^, bzw. wieso definierst Du 'hInstance' und verwendest 'hinst' <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f615.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--confused_face"
      title=":confused:"
      alt="😕"
    /> ...vllt. mal die etwas 'gründlicher' posten.<br />
Lass den Cast &quot;(DLGPROC)&quot; weg. Wenn Du die Funktion richtig definiert hast, ist der Cast auch nicht nötig. Das verdeckt nur Fehler.</p>
<p>Hast Du die Definition Deiner 'Test'-Funktion (oder mittlerweile wohl 'GoToProc'-Funktion) überarbeitet?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481056</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481056</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:40:25 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:41:50 GMT]]></title><description><![CDATA[<p>Doch hat es eh HINSTANCE hInstance=NULL;</p>
<p>Inwiefern überarbeitet?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481057</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481057</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:41:50 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:47:58 GMT]]></title><description><![CDATA[<p>WINAPI nooooobie schrieb:</p>
<blockquote>
<p>Doch hat es eh HINSTANCE hInstance=NULL;</p>
</blockquote>
<p>Na *das* hast Du in Deinem vorherigen Post aber nicht geschrieben. Außerdem brauchst Du ja den Handle des Moduls in dem die Resource liegt, meistens das aktuelle Modul (dann verwende zur Initialisierung einfach <code>GetModuleHandle(NULL)</code> ).</p>
<p>WINAPI nooooobie schrieb:</p>
<blockquote>
<p>Inwiefern überarbeitet?</p>
</blockquote>
<p>Überarbeitet in so fern, dass das:</p>
<p>WINAPI nooooobie schrieb:</p>
<blockquote>
<p>Callback vom Neuen Fenster:</p>
<pre><code class="language-cpp">BOOL CALLBACK Test(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam){

    switch (message)
	{
     case WM_INITDIALOG:
		{
			return TRUE;
		}
    }
}
</code></pre>
</blockquote>
<p>falsch ist.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481058</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481058</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:47:58 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:49:54 GMT]]></title><description><![CDATA[<p>Falls du das return FALSE meinst..<br />
Habe ich bereits ausgebessert...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481060</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481060</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:49:54 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 22:59:20 GMT]]></title><description><![CDATA[<p>Aber er kommt noch immer kein Fenster..</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481064</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481064</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 22:59:20 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:13:09 GMT]]></title><description><![CDATA[<p>Man check den Rückgabewert, check GETLASTERROR, <strong>GETLASTERROR</strong></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481069</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481069</guid><dc:creator><![CDATA[T2.0]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:13:09 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:14:58 GMT]]></title><description><![CDATA[<p>@T2.0</p>
<p>Sorry keiner wurde als Meister geboren...wenn du schon dann kannst es ja sicher auch zambringen das es läuft und hier posten...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481071</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481071</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:14:58 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:16:29 GMT]]></title><description><![CDATA[<p>Ich hab schon lange kein VC mehr installiert. Was sagt <strong>GETLASTERROR</strong>??????</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481072</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481072</guid><dc:creator><![CDATA[T2.0]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:16:29 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:29:19 GMT]]></title><description><![CDATA[<p>Was ich nicht anz verstehe ist, dass die Callback Funktion Test funktioniert da ich versucht habe in dem WM_INITDIALOG: eine MessageBox auszugeben!Diese wird auch ausgegeben nur erscheint das Fenster nicht...MFG</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481077</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481077</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:29:19 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:40:16 GMT]]></title><description><![CDATA[<p>WS_VISIBLE, ShowWindow, GetLastError, <a href="http://msdn2.microsoft.com/en-us/library/ms644996(VS.85).aspx" rel="nofollow">http://msdn2.microsoft.com/en-us/library/ms644996(VS.85).aspx</a></p>
<p>MfG,<br />
T2.0</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481078</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481078</guid><dc:creator><![CDATA[T2.0]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:40:16 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:44:07 GMT]]></title><description><![CDATA[<p>@T2.0</p>
<p>Ich hatte ja meinen Befehl schon gepostet...der Unterscheidet sich nciht von dem was in der MSDN steht...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481081</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481081</guid><dc:creator><![CDATA[WINAPI nooooobie]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:44:07 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:45:02 GMT]]></title><description><![CDATA[<p>Aber klaro, sonst würde es ja gehen, oder? Befolge meinen Rat und es wird gehen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1481082</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481082</guid><dc:creator><![CDATA[T2.0]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:45:02 GMT</pubDate></item><item><title><![CDATA[Reply to 2tes Fenster??? on Wed, 26 Mar 2008 23:48:05 GMT]]></title><description><![CDATA[<p>na ich will mal nicht so sein.</p>
<pre><code class="language-cpp">void ErrorMessage( PTCHAR lpErrorMsg ) {
	TCHAR szSysMsg[256], szMsg[1024];
	DWORD dwEnum;

	dwEnum = GetLastError();
	FormatMessage( FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS |
		FORMAT_MESSAGE_MAX_WIDTH_MASK, NULL, dwEnum,
		MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), szSysMsg, 256, 0 );

	_sntprintf( szMsg, 1024, _T(&quot;%s(%d)&quot;), szSysMsg, dwEnum );
	MessageBox( NULL, szMsg, lpErrorMsg, MB_ICONERROR );
}

...
...

if(!CreateDialog(blabla))
ErrorMessage(&quot;CreateDialog&quot;);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1481083</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1481083</guid><dc:creator><![CDATA[T2.0]]></dc:creator><pubDate>Wed, 26 Mar 2008 23:48:05 GMT</pubDate></item></channel></rss>