<?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[größe eines Listenelementes verändern]]></title><description><![CDATA[<p>hallo,</p>
<p>ich habe ein Listenelement in meiner Dialogbasierten-Anwendung erstellt<br />
und möchte es nun aber der Fenstergröße anpassen!</p>
<p>also wenn die fensergröße geändert wird (WM_SIZE) soll sich mein Listenelement mit anpassen.</p>
<p>wie kann ich die größe meines Listenelementes im nachhinein anpassen?</p>
<p>danke!</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/149366/größe-eines-listenelementes-verändern</link><generator>RSS for Node</generator><lastBuildDate>Wed, 22 Jul 2026 00:06:13 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/149366.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 05 Jun 2006 15:19:48 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 15:19:48 GMT]]></title><description><![CDATA[<p>hallo,</p>
<p>ich habe ein Listenelement in meiner Dialogbasierten-Anwendung erstellt<br />
und möchte es nun aber der Fenstergröße anpassen!</p>
<p>also wenn die fensergröße geändert wird (WM_SIZE) soll sich mein Listenelement mit anpassen.</p>
<p>wie kann ich die größe meines Listenelementes im nachhinein anpassen?</p>
<p>danke!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1071714</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1071714</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Mon, 05 Jun 2006 15:19:48 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 16:50:04 GMT]]></title><description><![CDATA[<p>Den Control verschiebst/zoomst Du mit (CWnd::)MoveWindow(x,y,cx,cy,TRUE). <a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_wcemfc4/html/aforiCWndMethods.asp" rel="nofollow">http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_wcemfc4/html/aforiCWndMethods.asp</a><br />
Wenn es das ganze Elternfenster einnehmen soll, kannst Du auch ShowWindow(SW_MAXIMIZE) abschießen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1071781</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1071781</guid><dc:creator><![CDATA[Erhard Henkes]]></dc:creator><pubDate>Mon, 05 Jun 2006 16:50:04 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 16:54:32 GMT]]></title><description><![CDATA[<p>hmm ich habs nun so probiert wie es in einem beispiel bei MSDN war:</p>
<pre><code>CRect myRect;
  GetClientRect(&amp;myRect);

  ClientToScreen(myRect);
  m_List1.MoveWindow(myRect.left, myRect.top,
    myRect.Width(), myRect.Height());
</code></pre>
<p>aber es kommt ein laufzeitfehler - warscheinlich weil ich</p>
<pre><code>m_List1.MoveWindow(...);
</code></pre>
<p>mache oder? aber wenn ich es ohne mache wird ja mein eigentliches fenster<br />
verändert und nicht nur meine Listbox!!</p>
<p>danke aber schonmal!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1071789</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1071789</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Mon, 05 Jun 2006 16:54:32 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 17:34:48 GMT]]></title><description><![CDATA[<p>ClientToScreen(myRect);<br />
.... das wäre nur nötig wenn du innerhald der Ctrl Klasse wärest...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1071815</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1071815</guid><dc:creator><![CDATA[*D*Evil]]></dc:creator><pubDate>Mon, 05 Jun 2006 17:34:48 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 18:48:59 GMT]]></title><description><![CDATA[<p>ja aber es klappt ja irgendwie nicht <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>
<p>das ist das problem! ich möchte NUR die größe der Listbox verändern!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1071852</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1071852</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Mon, 05 Jun 2006 18:48:59 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 20:29:09 GMT]]></title><description><![CDATA[<p>ja du sollst das ClientToScreen raushauen <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>
]]></description><link>https://www.c-plusplus.net/forum/post/1071908</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1071908</guid><dc:creator><![CDATA[*D*Evil]]></dc:creator><pubDate>Mon, 05 Jun 2006 20:29:09 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 22:27:10 GMT]]></title><description><![CDATA[<p>Ich denke, da klatscht irgend etwas zusammen (WM_SIZE von Elternfenster und MoveWindow() vom Kindfenster). Weiß leider momentan keine saubere Lösung. <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/1072017</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072017</guid><dc:creator><![CDATA[Erhard Henkes]]></dc:creator><pubDate>Mon, 05 Jun 2006 22:27:10 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Mon, 05 Jun 2006 22:29:00 GMT]]></title><description><![CDATA[<p>Du musst übrigens nicht alle Details vom vorhandenen Rechteck angeben, geht auch einfacher:</p>
<pre><code class="language-cpp">void MoveWindow( int x, int y, int nWidth, int nHeight, BOOL bRepaint = TRUE );
void MoveWindow( LPCRECT lpRect, BOOL bRepaint = TRUE );
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1072018</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072018</guid><dc:creator><![CDATA[Erhard Henkes]]></dc:creator><pubDate>Mon, 05 Jun 2006 22:29:00 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 09:13:08 GMT]]></title><description><![CDATA[<p>ja, aber auch wenn ich ClientToScreen(myRect); raushaue geht es nicht!</p>
<p>muss ich denn</p>
<pre><code>MoveWindow(...);
</code></pre>
<p>allein aufrufen? ne oder weil das gilt ja für das gesamte fenster!!<br />
ich muss doch</p>
<pre><code>m_List1.MoveWindow(...);
</code></pre>
<p>aufrufen oder? nur dann kommt bei mir nen laufzeitfehler :-|</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072263</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072263</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Tue, 06 Jun 2006 09:13:08 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 09:27:04 GMT]]></title><description><![CDATA[<p>Ja wie gesagt.<br />
1. Muss ClientToScreen raus...<br />
2. Einfach das Rect übergeben.<br />
3. Die MoveWindow Funktion von dem Ctrl benutzen.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072276</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072276</guid><dc:creator><![CDATA[*D*Evil]]></dc:creator><pubDate>Tue, 06 Jun 2006 09:27:04 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 10:15:11 GMT]]></title><description><![CDATA[<p>1. hab ich ja<br />
2. mach ich ja dann<br />
3. da kommt ja ein laufzeitfehler - das ist das problem</p>
<pre><code>CRect myRect;
GetClientRect(&amp;myRect);

//ClientToScreen(myRect);
m_List1.MoveWindow(myRect.left, myRect.top,myRect.Width(), myRect.Height());
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1072325</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072325</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Tue, 06 Jun 2006 10:15:11 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 19:19:07 GMT]]></title><description><![CDATA[<p>weis vieleicht jemand wie er mir weiterhelfen könnte? ^^</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072760</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072760</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Tue, 06 Jun 2006 19:19:07 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 21:14:10 GMT]]></title><description><![CDATA[<p>Im Release Mode sollte es laufen. Im Debug Mode erfolgt der Fehler in <strong>winocc.cpp</strong> bei folgender Stelle:</p>
<pre><code class="language-cpp">void CWnd::MoveWindow(int x, int y, int nWidth, int nHeight, BOOL bRepaint)
{
	ASSERT(::IsWindow(m_hWnd)); // Hier erfolgt die Fehlermeldung!

	if (m_pCtrlSite == NULL)
		::MoveWindow(m_hWnd, x, y, nWidth, nHeight, bRepaint);
	else
		m_pCtrlSite-&gt;MoveWindow(x, y, nWidth, nHeight, bRepaint);
}
</code></pre>
<p>Das <strong>ASSERT(...)</strong> schlägt Alarm, weil m_hWnd gleich 0 ist, also kein gültiges Fensterhandle.</p>
<p>Damit könnte es gehen:</p>
<pre><code class="language-cpp">CRect myRect;
GetClientRect(&amp;myRect);
HWND hWnd = m_List1.GetSafeHwnd(); //Wir beschaffen uns ein gültiges Handle!
::MoveWindow(hWnd, myRect.left, myRect.top, myRect.Width(), myRect.Height(), TRUE);
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1072834</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072834</guid><dc:creator><![CDATA[Erhard Henkes]]></dc:creator><pubDate>Tue, 06 Jun 2006 21:14:10 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 21:14:32 GMT]]></title><description><![CDATA[<p>@Erhard Henkes</p>
<p>vielen Danke! nun klappt es perfekt!!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1072840</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072840</guid><dc:creator><![CDATA[Andreas M.]]></dc:creator><pubDate>Tue, 06 Jun 2006 21:14:32 GMT</pubDate></item><item><title><![CDATA[Reply to größe eines Listenelementes verändern on Tue, 06 Jun 2006 21:17:58 GMT]]></title><description><![CDATA[<p>Freut mich, dass ich doch noch helfen konnte. <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>
]]></description><link>https://www.c-plusplus.net/forum/post/1072844</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1072844</guid><dc:creator><![CDATA[Erhard Henkes]]></dc:creator><pubDate>Tue, 06 Jun 2006 21:17:58 GMT</pubDate></item></channel></rss>