<?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[welche message fuer listbox ohne focus?]]></title><description><![CDATA[<p>heiho</p>
<p>es geht darum, wenn man in einer listbox so einige sachen stehen hat sodass die verticale scrollbar auftaucht - kann man scrollen ohne das man in das fenster selber rein klickt - also nur auf den pfeilen fuer rauf und runter</p>
<p>das problem ist, diese aktion moechte ich abfangen</p>
<p>command und dann die ID der liste bekomm ich nur wenn ich in die liste direkt rein klicke, aber wenn ich nur scrolle und ein anderes fenster den focus behaellt - bekomm ich keine message - bzw weiss nicht welche ich abfangen muss - spy++ sagte mir nichts bis auf die maus bewegungen</p>
<p>die frage nu - wie kann ich diese scroll bewegungen abfangen ?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/182490/welche-message-fuer-listbox-ohne-focus</link><generator>RSS for Node</generator><lastBuildDate>Tue, 07 Jul 2026 12:42:27 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/182490.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 25 May 2007 13:13:21 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 13:13:21 GMT]]></title><description><![CDATA[<p>heiho</p>
<p>es geht darum, wenn man in einer listbox so einige sachen stehen hat sodass die verticale scrollbar auftaucht - kann man scrollen ohne das man in das fenster selber rein klickt - also nur auf den pfeilen fuer rauf und runter</p>
<p>das problem ist, diese aktion moechte ich abfangen</p>
<p>command und dann die ID der liste bekomm ich nur wenn ich in die liste direkt rein klicke, aber wenn ich nur scrolle und ein anderes fenster den focus behaellt - bekomm ich keine message - bzw weiss nicht welche ich abfangen muss - spy++ sagte mir nichts bis auf die maus bewegungen</p>
<p>die frage nu - wie kann ich diese scroll bewegungen abfangen ?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292235</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292235</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 13:13:21 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 14:06:54 GMT]]></title><description><![CDATA[<p>Wenn die Listbox &quot;gesubclassed&quot; wäre, kannst Du &quot;WM_VSCROLL&quot; abfangen und behandeln.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292264</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292264</guid><dc:creator><![CDATA[[[global:guest]]]]></dc:creator><pubDate>Fri, 25 May 2007 14:06:54 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 14:10:39 GMT]]></title><description><![CDATA[<p>hab ich gesubclasst - wie alle meine listboxen und checkboxen usw - aber das WM_VSCROLL kommt nie beim parent an</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292267</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292267</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 14:10:39 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 14:14:53 GMT]]></title><description><![CDATA[<p>Soll ja auch nicht. Was soll der Parent damit anfangen ?<br />
Kannst Du die nicht in der entsprechenden WinProc behandeln ?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292270</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292270</guid><dc:creator><![CDATA[[[global:guest]]]]></dc:creator><pubDate>Fri, 25 May 2007 14:14:53 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 15:25:39 GMT]]></title><description><![CDATA[<p>dir ist klar das das hier winapi ist ?</p>
<p>ich habe die main prozedur, also das erstellen des haupt fensters global<br />
dann hab ich eine klasse welche instanziiert wird - diese bekommt das instance und handle von diesem fenster<br />
und dort wird das create mit der richtigen main handle aufgerufen</p>
<p>die messages sollen alle in der WinProc landen also in der message table der haupt fensters - tun sie aber nicht</p>
<p>// dazuedit</p>
<p>ich hab mal probiert - ich ruf das create der listbox direkt in der WndProc auf bei WM_CREATE - also nichts mehr mit irgendeiner klasse - trotzdem kommen die messages nicht an ?!</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292294</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292294</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 15:25:39 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 15:35:48 GMT]]></title><description><![CDATA[<p>achso damit man es nun besser versteht - hier der relevante code:</p>
<pre><code class="language-cpp">/*........*/
// handle for the listbox
HWND m_Handle;

/*........*/
// the one and only main
int APIENTRY _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdLine, int nCmdShow)

}
/*........*/

// main message proc
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
{
    int wmId;
    int wmEvent;
    PAINTSTRUCT ps;
    HDC hdc;

    switch (message)
    {

    // dieses WM_VSCROLL wird nie aufgerufen - das ist das problem
    case WM_VSCROLL:
        {
            int i = 0;
        }
        break;
/*........*/

    case WM_CREATE:
        {
            // erstelle die listbox
            m_Handle = ::CreateWindow(_T(&quot;listbox&quot;), _T(&quot;&quot;), WS_CHILD|WS_VISIBLE|WS_BORDER|WS_HSCROLL|WS_VSCROLL|WS_TABSTOP|WS_GROUP, 146, 200, 35, 30, hWnd, reinterpret_cast&lt;HMENU&gt;(static_cast&lt;ULONG_PTR&gt;(ID_LIST)), 0, 0);

            // fuelle listbox mit striongs vo n1 bis 200 damit scrollbalken erscheint            
            evl::tchar_ptr buff(4);
            for(int i = 1; i &lt;= 200; ++i)
            {
                buff.Format(_T(&quot;%d&quot;), i);
                ::SendMessage(m_Handle, LB_ADDSTRING, 0, reinterpret_cast&lt;LPARAM&gt;(buff.string()));
            }
        }
        break;

/*........*/
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1292302</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292302</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 15:35:48 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 15:46:54 GMT]]></title><description><![CDATA[<p>Also so ganz hab ich dich nicht verstanden und ich seh auch nicht wo du subclassed? Bist du dir sicher das Wir hier von dem selben reden? Hier ist mal ein Bsp. für Subclassen <a href="http://www.winapi.net/index.php?inhalt=s27" rel="nofollow">http://www.winapi.net/index.php?inhalt=s27</a></p>
<p>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292310</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292310</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Fri, 25 May 2007 15:46:54 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 15:55:54 GMT]]></title><description><![CDATA[<p>ich hab den code ja zum test geaendert siehe mein post - so wie es jetzt da steht muesste die message doch in der WinProc landen - das tuts nicht, und das versteh ich nicht warum nicht</p>
<p>grad mal das subclassing probiert wie in deinem link gezeigt, da gehts</p>
<p>darum die frage - warum bekomm ich die message nicht in der WndProc?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292314</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292314</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 15:55:54 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 16:03:05 GMT]]></title><description><![CDATA[<p>Ja warum sollte sie denn? Also was ich sehe ist das du ne Listbox erstellst und mehr nicht. Da ist doch nix gesubclasst.<br />
Und wenn es mit dem link funktioniert dann mach es so. Wie gesagt vielleicht reden wir ja aneinander vorbei und ich mein mit subclassen etwas anderes als du <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="🙂"
    /> /EDIT Ich mein das richtige <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>schirrmie</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292324</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292324</guid><dc:creator><![CDATA[schirrmie]]></dc:creator><pubDate>Fri, 25 May 2007 16:03:05 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 16:12:05 GMT]]></title><description><![CDATA[<p>hatte das subclass falsch verstanden - lag daran das ich meinen wrapper benutze und dort sind alle elemente in klassen</p>
<p>ich hab das jetzt so gemacht das die liste eine eigene message prozedur bekommt wie in der liste - und dort leite ich dann die WM_VSCROLL an die main weiter</p>
<p>vielen dank dafuer - nun hab ich genau was ich brauch {=</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1292333</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292333</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 16:12:05 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 16:22:41 GMT]]></title><description><![CDATA[<p>Mr Evil schrieb:</p>
<blockquote>
<p>dir ist klar das das hier winapi ist ?</p>
</blockquote>
]]></description><link>https://www.c-plusplus.net/forum/post/1292340</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292340</guid><dc:creator><![CDATA[[[global:guest]]]]></dc:creator><pubDate>Fri, 25 May 2007 16:22:41 GMT</pubDate></item><item><title><![CDATA[Reply to welche message fuer listbox ohne focus? on Fri, 25 May 2007 17:28:47 GMT]]></title><description><![CDATA[<p>jops - weil &quot;subclassing&quot; bedeutet fuer mich</p>
<pre><code class="language-cpp">class Foo
{
    int a;
};

class Bar
{
    Foo foo; // classe ein element von anderer klasse - daher subclassing
};
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1292365</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1292365</guid><dc:creator><![CDATA[EXDW]]></dc:creator><pubDate>Fri, 25 May 2007 17:28:47 GMT</pubDate></item></channel></rss>