<?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[fenster layer?]]></title><description><![CDATA[<p>ich habe folgendes problem: ich schreibe grad nen dialog, mit dem man dateien auswählen und öffnen kann. nur muss ich diesem dialog 2 eigenschaften geben:<br />
1. wenn das dielogfenster da ist, muss es über allen andren fenstern liegen, so dass es nicht z.B. hinter nem textedit verschwinden kann!<br />
2. die anderen windows müssen gesperrt sein, so dass man sie nicht anklicken kann!</p>
<p>wie krieg ich dat hin?</p>
<p>danke</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/77709/fenster-layer</link><generator>RSS for Node</generator><lastBuildDate>Sat, 11 Apr 2026 23:13:15 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/77709.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 23 Jun 2004 16:08:21 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to fenster layer? on Wed, 23 Jun 2004 16:08:41 GMT]]></title><description><![CDATA[<p>ich habe folgendes problem: ich schreibe grad nen dialog, mit dem man dateien auswählen und öffnen kann. nur muss ich diesem dialog 2 eigenschaften geben:<br />
1. wenn das dielogfenster da ist, muss es über allen andren fenstern liegen, so dass es nicht z.B. hinter nem textedit verschwinden kann!<br />
2. die anderen windows müssen gesperrt sein, so dass man sie nicht anklicken kann!</p>
<p>wie krieg ich dat hin?</p>
<p>danke</p>
]]></description><link>https://www.c-plusplus.net/forum/post/546554</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/546554</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Wed, 23 Jun 2004 16:08:41 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Wed, 23 Jun 2004 16:15:51 GMT]]></title><description><![CDATA[<p>Hi,</p>
<p>1. SetWindowPos(..., HWND_TOPMOST, ...)</p>
<p>2. und als Parent ein Popup-Wnd über den ganzen Bildschirm ... darauf musst du dann aber den voherigen Screen zeichnen.</p>
<p>M.T.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/546570</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/546570</guid><dc:creator><![CDATA[Manuel]]></dc:creator><pubDate>Wed, 23 Jun 2004 16:15:51 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:14:43 GMT]]></title><description><![CDATA[<p>danke...ich hab das mit setwindowblabla mal ausprobiert, hab aber immernoch den gleichen fehler! das fenster kommt vor ne editbox und wird an der stelle dann weiss, als würde es nie neugezeichnet ! wie krieg ichs hin, dass das fenster wirklich einfach wie eine fehlermeldung oder sowas VOR allem andren ist? wenn ich den style WS_POPUPWINDOW benutze ist das fenster garnicht erst zu sehn!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547115</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547115</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:14:43 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:22:18 GMT]]></title><description><![CDATA[<p>einfach warten bis das Fenster die message WM_KILLFOCUS erhält und dann 0 returnen. Damit kann dien Fenster den Focus nicht verlieren.</p>
<p>Mfg.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547123</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547123</guid><dc:creator><![CDATA[Tolga]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:22:18 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:23:47 GMT]]></title><description><![CDATA[<p>Indem Du den Dialog Modal machst, also als hwndParent dein Hauptfenster angibst.</p>
<p>Warum benutzt Du zum Dateien öffnen nicht den Common Dialog (GetOpenFileName)?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547126</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547126</guid><dc:creator><![CDATA[Hepi]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:23:47 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:26:56 GMT]]></title><description><![CDATA[<p><a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/DialogBoxes/UsingDialogBoxes.asp#modal_box" rel="nofollow">http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/DialogBoxes/UsingDialogBoxes.asp#modal_box</a></p>
<p>wenn di dialogbox benutzt solltest ein parent fenster angeben.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547128</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547128</guid><dc:creator><![CDATA[miller_m]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:26:56 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:29:09 GMT]]></title><description><![CDATA[<p>super danke!<br />
is der common dialog nicht mfc?</p>
<p>edit: ich hab doch das hauptfenster als parent?!</p>
<pre><code class="language-cpp">HWND fileSearch = CreateWindowEx (
								  WS_EX_TOOLWINDOW,
						   szName,
						   &quot;Oeffnen&quot;, 
                           WS_CHILD | WS_OVERLAPPEDWINDOW /*| WS_POPUPWINDOW*/
						   ,
                           320,
						   5,
						   400,
						   150, 
                           hwnd,
						   (HMENU)3,
						   NULL,
						   NULL
						   );
ShowWindow   (fileSearch, SW_SHOWNORMAL); 
UpdateWindow (fileSearch);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/547129</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547129</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:29:09 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:29:06 GMT]]></title><description><![CDATA[<p>vieeeeell zu laaaangsam. <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>nein der common dialog ist kein mfc.<br />
<a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/UserInput/CommonDialogBoxLibrary/UsingCommonDialogBoxes.asp#open_file" rel="nofollow">http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/UserInput/CommonDialogBoxLibrary/UsingCommonDialogBoxes.asp#open_file</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/547134</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547134</guid><dc:creator><![CDATA[miller_m]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:29:06 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 12:31:29 GMT]]></title><description><![CDATA[<p>zum edit von pixartist<br />
ich dacht wir reden über dialoge.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547137</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547137</guid><dc:creator><![CDATA[miller_m]]></dc:creator><pubDate>Thu, 24 Jun 2004 12:31:29 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 13:02:46 GMT]]></title><description><![CDATA[<p>??? nein ich meinte mit dialog ein fenster genau wie den common dialog...ich nehm jetzt mal den ^^ nur hab ich das problem, dass ich nicht weiss wie ich denn nun an den inhalt der datei komme! das is im msdn auchnicht beschrieben...?</p>
<pre><code class="language-cpp">OPENFILENAME ofn;       // common dialog box structure
			char szFile[260];       // buffer for file name
			HANDLE hf;
			// Los Gehts (MSDN krams)
			//Memory leeren:
			ZeroMemory(&amp;ofn, sizeof(ofn));
			//Grösse, Owner, File...
			ofn.lStructSize = sizeof(ofn);
			ofn.hwndOwner = hwnd;
			ofn.lpstrFile = szFile;

			//
			// Set lpstrFile[0] to '\0' so that GetOpenFileName does not 
			// use the contents of szFile to initialize itself.
			//
			//Anm,: ???
			ofn.lpstrFile[0] = '\0';
			ofn.nMaxFile = sizeof(szFile);
			ofn.lpstrFilter = &quot;All\0*.*\0Text\0*.TXT\0&quot;;
			ofn.nFilterIndex = 1;
			ofn.lpstrFileTitle = NULL;
			ofn.nMaxFileTitle = 0;
			ofn.lpstrInitialDir = NULL;
			ofn.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST;
			if (GetOpenFileName(&amp;ofn)==TRUE) 
				hf = CreateFile(ofn.lpstrFile, GENERIC_READ, 0, (LPSECURITY_ATTRIBUTES) NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, (HANDLE) NULL);
			//oO wat is wacken?
			SetWindowText(textField, /*Woher krieg ich den inhalt der datei??*/);
			SetWindowText(fileZeiger, szFile);
</code></pre>
<p>edit achja un könnt ihr mir nochmal erklären was der unterschied zwischen dialog und fenster ist?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547159</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547159</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Thu, 24 Jun 2004 13:02:46 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 13:11:35 GMT]]></title><description><![CDATA[<p>Na, GetOpenFileName / GetSaveFileName liefert Dir den Pfad zur Datei, die der User geöffnet/gespeichert haben will.</p>
<p>Wenn Du den Pfad hast, mußt Du sie schon selbst öffnen (CreateFile... OPEN_EXISTING) und auslesen (ReadFile...) bzw. schreiben (WriteFile...)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547186</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547186</guid><dc:creator><![CDATA[Hepi]]></dc:creator><pubDate>Thu, 24 Jun 2004 13:11:35 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 13:22:05 GMT]]></title><description><![CDATA[<p>pixartist schrieb:</p>
<blockquote>
<p>edit achja un könnt ihr mir nochmal erklären was der unterschied zwischen dialog und fenster ist?</p>
</blockquote>
<p>im prinzip sind beides fenster. <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="😃"
    /> ich ging nur davon aus das dein dialog/fenster<br />
mit dialogbox oder ähnliches aufrufst.</p>
<p>aber vergleiche selber<br />
<a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/DialogBoxes.asp" rel="nofollow">http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/DialogBoxes.asp</a><br />
<a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/Windows.asp" rel="nofollow">http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/Windowing/Windows.asp</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/547195</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547195</guid><dc:creator><![CDATA[miller_m]]></dc:creator><pubDate>Thu, 24 Jun 2004 13:22:05 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 13:26:19 GMT]]></title><description><![CDATA[<p>aso <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="😃"
    /> ja danke habs grad auch im msdn gefunden... trotzdem klappts noch nicht <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f61e.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--disappointed_face"
      title=":("
      alt="😞"
    /> memory error</p>
<pre><code class="language-cpp">unsigned long nRead = GetFileSize(hf,NULL);
			char *lpbuffer = new char[nRead];
			lpbuffer[nRead] = 0;
			ReadFile( 
			hf, 
			lpbuffer, 
			nRead-1, 
			NULL, 
			NULL
			);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/547210</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547210</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Thu, 24 Jun 2004 13:26:19 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 16:37:59 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">TCHAR* DiaOpen(bool open)
{
TCHAR* buffer = new TCHAR[300];
ZeroMemory(buffer, 300);
lstrcpy(buffer,TEXT(&quot;*&quot;));

OPENFILENAME ofn;
ofn.lStructSize = sizeof(OPENFILENAME);
ofn.hwndOwner = hMain;
ofn.hInstance = hInstance;
ofn.lpstrFilter = TEXT(&quot;All File Types&quot;);
ofn.lpstrCustomFilter = NULL;
ofn.nMaxCustFilter = NULL;
ofn.nFilterIndex = 14;
ofn.lpstrFile = buffer;
ofn.nMaxFile = 300;
ofn.lpstrFileTitle = NULL;
ofn.nMaxFileTitle = NULL;
ofn.lpstrInitialDir = NULL;
ofn.lpstrTitle = TEXT(&quot;Öffnen - Titel&quot;);
if (!(open))
	ofn.lpstrTitle = TEXT(&quot;Speicher - Titel&quot;);
ofn.Flags = OFN_FILEMUSTEXIST|OFN_HIDEREADONLY|OFN_NONETWORKBUTTON|OFN_PATHMUSTEXIST;
ofn.nFileOffset = NULL;
ofn.nFileExtension = NULL;
ofn.lpstrDefExt = NULL;
ofn.lCustData = NULL;
ofn.lpfnHook = NULL;
ofn.lpTemplateName = NULL;

if( (!(GetOpenFileName(&amp;ofn))) &amp;&amp; (0==CommDlgExtendedError()))
		lstrcpy(buffer,TEXT(&quot;CANCELLED&quot;)); //Wennnd er suer beendet oder abbricht
return buffer;
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/547312</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547312</guid><dc:creator><![CDATA[Tolga]]></dc:creator><pubDate>Thu, 24 Jun 2004 16:37:59 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Thu, 24 Jun 2004 22:34:39 GMT]]></title><description><![CDATA[<p>aber wieso geht das denn nicht:</p>
<pre><code class="language-cpp">OPENFILENAME ofn;       // common dialog box structure
			char szFile[260];       // buffer for file name
			HANDLE hf;
			// Los Gehts (MSDN krams)
			//Memory leeren:
			ZeroMemory(&amp;ofn, sizeof(ofn));
			//Grösse, Owner, File...
			ofn.lStructSize = sizeof(ofn);
			ofn.hwndOwner = hwnd;
			ofn.lpstrFile = szFile;

			//
			// Set lpstrFile[0] to '\0' so that GetOpenFileName does not 
			// use the contents of szFile to initialize itself.
			//
			//Anm,: ???
			ofn.lpstrFile[0] = '\0';
			ofn.nMaxFile = sizeof(szFile);
			ofn.lpstrFilter = &quot;All\0*.*\0Text\0*.TXT\0&quot;;
			ofn.nFilterIndex = 1;
			ofn.lpstrFileTitle = NULL;
			ofn.nMaxFileTitle = 0;
			ofn.lpstrInitialDir = NULL;
			ofn.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST;
			if (GetOpenFileName(&amp;ofn)==TRUE) 
				hf = CreateFile(ofn.lpstrFile, GENERIC_READ, 0, (LPSECURITY_ATTRIBUTES) NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, (HANDLE) NULL);
			//oO wat is wacken?
			unsigned long nRead = GetFileSize(hf,NULL);
			char *lpbuffer = new char[nRead];
			lpbuffer[nRead] = 0;
			SetFilePointer(hf,0,NULL,FILE_BEGIN);
			char len;
			itoa(int(nRead),&amp;len,36);
			MessageBox(NULL, &amp;len, &quot;&quot;,0);
			/*ReadFile( 
			hf, 
			lpbuffer, 
			nRead, 
			NULL, 
			NULL
			); */
			SetWindowText(textField, lpbuffer);
			SetWindowText(fileZeiger, szFile);
</code></pre>
<p>edit: LOL die funktion da oben gibt nur den filename zurück oO</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547484</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547484</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Thu, 24 Jun 2004 22:34:39 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 08:07:45 GMT]]></title><description><![CDATA[<p>Ist dir dann jetzt alles klar, oder gibt's noch Probleme?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547611</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547611</guid><dc:creator><![CDATA[flenders]]></dc:creator><pubDate>Fri, 25 Jun 2004 08:07:45 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 09:53:27 GMT]]></title><description><![CDATA[<p>wahahah ich kriege mit tolgas funktion doch immernoch nur den DATEINAMEN zurück! ich will aber den dateiinhalt! und bei meiner funktion kriege ich nen memory error obwohl ich mich an msdn halte!!</p>
<pre><code class="language-cpp">OPENFILENAME ofn;       // common dialog box structure
			char szFile[260];       // buffer for file name
			HANDLE hf;
			// Los Gehts (MSDN krams)
			//Memory leeren:
			ZeroMemory(&amp;ofn, sizeof(ofn));
			//Grösse, Owner, File...
			ofn.lStructSize = sizeof(ofn);
			ofn.hwndOwner = hwnd;
			ofn.lpstrFile = szFile;
			//
			// Set lpstrFile[0] to '\0' so that GetOpenFileName does not 
			// use the contents of szFile to initialize itself.
			//
			//Anm,: ???
			ofn.lpstrFile[0] = '\0';
			ofn.nMaxFile = sizeof(szFile);
			ofn.lpstrFilter = &quot;All\0*.*\0Text\0*.TXT\0&quot;;
			ofn.nFilterIndex = 1;
			ofn.lpstrFileTitle = NULL;
			ofn.nMaxFileTitle = 0;
			ofn.lpstrInitialDir = NULL;
			ofn.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST;
			if (GetOpenFileName(&amp;ofn)==TRUE) 
				hf = CreateFile(ofn.lpstrFile, GENERIC_READ, 0, (LPSECURITY_ATTRIBUTES) NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, (HANDLE) NULL);
			//oO wat is wacken?
			unsigned long nRead = GetFileSize(hf,NULL);
			char *lpbuffer = new char[nRead];
			lpbuffer[nRead] = 0;
			SetFilePointer(hf,0,NULL,FILE_BEGIN);
			char len;
			itoa(nRead,&amp;len,36);
			MessageBox(NULL, &amp;len, &quot;&quot;,0);//&lt;--------------HIER
			ReadFile( 
			hf, 
			lpbuffer, 
			nRead, 
			NULL, 
			NULL
			); 
			SetWindowText(textField, lpbuffer);
			SetWindowText(fileZeiger, szFile);
</code></pre>
<p>bei der msg box bekomme ich seltsamerweise immer sowas: 13c oder 2f5 oder sowas! auf jedenfall krieg ich nen memory fehler beim ausführen des ReadFile() !!! wiesoe <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="😕"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/547703</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547703</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Fri, 25 Jun 2004 09:53:27 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:03:38 GMT]]></title><description><![CDATA[<p>- len sollte eine grösse habe wie zb 20<br />
- der msgbox übergibst du adresse von len, &amp; weglassen</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547709</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547709</guid><dc:creator><![CDATA[miller_m]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:03:38 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:11:55 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">char *len = new char[5];
len[5] = 0;
itoa(nRead,len,36);
MessageBox(NULL, len, &quot;&quot;,0);
</code></pre>
<p>so?<br />
macht keinen unterschied, aber die msgbox ist ja nicht das problem, sonder ReadFile() !<br />
die msgbox hab ich ja nur um den wert zu überprüfen!</p>
<p>edit:irgendwas verweist auf 0x000000 ?! deswegen der memory error..</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547716</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547716</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:11:55 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:28:04 GMT]]></title><description><![CDATA[<p>pixartist schrieb:</p>
<blockquote>
<p>edit:irgendwas verweist auf 0x000000 ?! deswegen der memory error..</p>
</blockquote>
<p>&quot;irgendwas&quot;?</p>
<p>Was denn genau? Bei mir zeigt &quot;irgendwas&quot; auch immer auf NULL... <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>Außerdem sehe ich nirgends, wo Du die Datei auch ausliest... nirgendwo wird bei Dir ReadFile() aufgerufen... oder sehe ich's nur nicht?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547724</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547724</guid><dc:creator><![CDATA[Hepi]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:28:04 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:27:26 GMT]]></title><description><![CDATA[<p><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="😕"
    /> <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f62e.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--face_with_open_mouth"
      title=":open_mouth:"
      alt="😮"
    /></p>
<p>also erstmal: 0x77e5abd2 verweist auf Speicher 0x00000000 der vorgang written konnte nicht auf den speicher ausgeführt werden.</p>
<p>und zweitens: natürlich benutze ich readfile!!</p>
<pre><code class="language-cpp">OPENFILENAME ofn;       // common dialog box structure
            char szFile[260];       // buffer for file name
            HANDLE hf;
            // Los Gehts (MSDN krams)
            //Memory leeren:
            ZeroMemory(&amp;ofn, sizeof(ofn));
            //Grösse, Owner, File...
            ofn.lStructSize = sizeof(ofn);
            ofn.hwndOwner = hwnd;
            ofn.lpstrFile = szFile;
            //
            // Set lpstrFile[0] to '\0' so that GetOpenFileName does not 
            // use the contents of szFile to initialize itself.
            //
            //Anm,: ???
            ofn.lpstrFile[0] = '\0';
            ofn.nMaxFile = sizeof(szFile);
            ofn.lpstrFilter = &quot;All\0*.*\0Text\0*.TXT\0&quot;;
            ofn.nFilterIndex = 1;
            ofn.lpstrFileTitle = NULL;
            ofn.nMaxFileTitle = 0;
            ofn.lpstrInitialDir = NULL;
            ofn.Flags = OFN_PATHMUSTEXIST | OFN_FILEMUSTEXIST;
            if (GetOpenFileName(&amp;ofn)==TRUE) 
                hf = CreateFile(ofn.lpstrFile, GENERIC_READ, 0, (LPSECURITY_ATTRIBUTES) NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, (HANDLE) NULL);
            //oO wat is wacken?
            unsigned long nRead = GetFileSize(hf,NULL);
            char *lpbuffer = new char[nRead];
            lpbuffer[nRead] = 0;
            SetFilePointer(hf,0,NULL,FILE_BEGIN);
            char len;
            itoa(nRead,&amp;len,36);
            MessageBox(NULL, &amp;len, &quot;&quot;,0);//&lt;--------------HIER
            ReadFile( //&lt;----------------ReadFile() !!!
            hf,       //----
            lpbuffer, //----
            nRead,    //----
            NULL,     //----
            NULL      //----
            );        //---- Bis hier!
            SetWindowText(textField, lpbuffer);
            SetWindowText(fileZeiger, szFile);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/547732</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547732</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:27:26 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:30:01 GMT]]></title><description><![CDATA[<p>pixartist schrieb:</p>
<blockquote>
<p>also erstmal: 0x77e5abd2 verweist auf Speicher 0x00000000 der vorgang written konnte nicht auf den speicher ausgeführt werden.</p>
</blockquote>
<p>Also mit der Angabe kann hier keiner was anfangen... welcher Zeiger zeigt denn auf NULL (frag Deinen Debugger mal, der weiß sowas).</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547735</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547735</guid><dc:creator><![CDATA[Hepi]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:30:01 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:34:28 GMT]]></title><description><![CDATA[<p>is der code denn grundsätzlich ok?<br />
wenn ich den debugger starte kriege ich:</p>
<pre><code>Geladene Symbole für &quot;D:\Programme\C++ files\MSDev98\MyProjects\test\Debug\test.exe&quot;
&quot;C:\WINDOWS\system32\ntdll.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\kernel32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\user32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\gdi32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\advapi32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\rpcrt4.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\comdlg32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\shlwapi.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\msvcrt.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\comctl32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\shell32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.10.0_x-ww_f7fb5805\comctl32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\uxtheme.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\Programme\Logitech\MouseWare\system\LgWndHk.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\msctf.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\Programme\Gemeinsame Dateien\Logitech\Scrolling\LGMSGHK.DLL&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\msvcp60.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\mslbui.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\oleaut32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\ole32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\apphelp.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\clbcatq.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\comres.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\version.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\setupapi.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\ntshrui.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\atl.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\netapi32.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\userenv.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
&quot;C:\WINDOWS\system32\shdocvw.dll&quot; wurde geladen. Es wurden keine entsprechenden Symbolinformationen gefunden.
Thread 0x330 wurde mit Code 0 (0x0) beendet.
Thread 0xA98 wurde mit Code -1073741819 (0xC0000005) beendet.
Thread 0xAB4 wurde mit Code -1073741819 (0xC0000005) beendet.
Thread 0xAA4 wurde mit Code -1073741819 (0xC0000005) beendet.
Thread 0xAA8 wurde mit Code -1073741819 (0xC0000005) beendet.
Thread 0xA74 wurde mit Code -1073741819 (0xC0000005) beendet.
Das Programm &quot;D:\Programme\C++ files\MSDev98\MyProjects\test\Debug\test.exe&quot; wurde mit  Code -1073741819 (0xC0000005) beendet.
</code></pre>
<p>edit: ich hoffe das ist was du willst, ich kenn mich nicht mitm debugger aus. bin anfänger <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f61e.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--disappointed_face"
      title=":("
      alt="😞"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/547739</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547739</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:34:28 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:37:26 GMT]]></title><description><![CDATA[<p>pixartist schrieb:</p>
<blockquote>
<p>is der code denn grundsätzlich ok?</p>
</blockquote>
<p>Wenn Du mit dem ständigen Abstürzen leben kannst, ja. <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>pixartist schrieb:</p>
<blockquote>
<p>wenn ich den debugger starte kriege ich:</p>
</blockquote>
<p>Möchtest Du, bevor wir hier weitermachen, nicht erstmal die Bedienung und den Umgang mit einem Debugger lernen?</p>
<p>Such mal hier im Forum nach dem Wort &quot;Debugger&quot;, ich glaube hier hatte mal jemand ein kleines Grundlagentutorial gepostet (BreakPoints usw.)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547741</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547741</guid><dc:creator><![CDATA[Hepi]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:37:26 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:39:00 GMT]]></title><description><![CDATA[<p>Fällt das niemandem auf?</p>
<pre><code class="language-cpp">char *len = new char[5]; 
len[5] = 0; // Du schreibst hier über die Grenzen des Arrays!
itoa(nRead,len,36); 
MessageBox(NULL, len, &quot;&quot;,0)
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/547746</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547746</guid><dc:creator><![CDATA[Aziz]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:39:00 GMT</pubDate></item><item><title><![CDATA[Reply to fenster layer? on Fri, 25 Jun 2004 10:43:17 GMT]]></title><description><![CDATA[<p><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="😃"
    /> ja gern, erklähr doch mal <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="😃"
    /> <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /> äh muss ich jetzt was kompliziertes machen oder ist das was du möchtest n einfacher handgriff? wenn es was einfaches ist würde ich mich freuen wenn du mir kurz sagst was ich machen muss, dann werde ich mich später mit dem debugger beschäftigen <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="🙂"
    /> wenns komplizierter ist, kannste mir n tut oder so empfehlen?</p>
<p>edit: hab jetzt n debug gestartet..und beim fehler zeigt er mir folgende zeile an:</p>
<pre><code>77E5ABD2   mov         dword ptr [ecx],eax
</code></pre>
<p>edit: aziz, den messagebox kram hab ich schon lange rausgenommen...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/547747</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/547747</guid><dc:creator><![CDATA[pixartist]]></dc:creator><pubDate>Fri, 25 Jun 2004 10:43:17 GMT</pubDate></item></channel></rss>