<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : How to apply menus (xp style) to dialog ?</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Toolkit Pro : How to apply menus (xp style) to dialog ?]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 22 Apr 2026 06:51:17 +0000</pubDate>
  <lastBuildDate>Sat, 26 Nov 2005 13:10:39 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=3272</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : Ok.. thx.. I did that and now...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9820&amp;title=how-to-apply-menus-xp-style-to-dialog#9820</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1577">jigarmehtamscit</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 26 November 2005 at 1:10pm<br /><br />Ok.. thx.. I did that and now its working.. Thx for the help..]]>
   </description>
   <pubDate>Sat, 26 Nov 2005 13:10:39 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9820&amp;title=how-to-apply-menus-xp-style-to-dialog#9820</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : SetPaneText can be called only...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9808&amp;title=how-to-apply-menus-xp-style-to-dialog#9808</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 26 November 2005 at 6:45am<br /><br /><P>SetPaneText can be called only from thread created status bar, </P><P>but you can send some message like:</P><P>#deifne MY_TEXT_CHANGED (WM_APP + 2)</P><P>pDlg-&gt;SendMessage(MY_TEXT_CHANGED);</P><P>&nbsp;</P><P>and in CAppGUIDlg&nbsp; catch it and set status text.</P><P>&nbsp;</P>]]>
   </description>
   <pubDate>Sat, 26 Nov 2005 06:45:09 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9808&amp;title=how-to-apply-menus-xp-style-to-dialog#9808</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? :    oleg wrote:Why you need static...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9796&amp;title=how-to-apply-menus-xp-style-to-dialog#9796</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1577">jigarmehtamscit</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 25 November 2005 at 2:04pm<br /><br /><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by oleg" alt="Originally posted by oleg" style="vertical-align: text-bottom;" /> <strong>oleg wrote:</strong><br /><br /><p>Why you need static text, if you can update text directly to status bar</p><p>&nbsp;</p><p>m_wndStatusBar.SetPaneText(...) ?</p></td></tr></table><br><br>What if we want to set the m_wndStatusBar.SetPaneText from a global thread ?? Following is my code for reference..<br><br><br>UINT threadBackgroundTask(LPVOID lParam)<br>{<br>&nbsp;&nbsp;&nbsp; CAppGUIDlg *pDlg;<br>&nbsp;&nbsp;&nbsp; pDlg = (CAppGUIDlg *)lParam;<br><br>&nbsp;&nbsp;&nbsp; while(1)<br>&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if(pDlg != NULL)<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; pDlg-&gt;m_wndStatusBar.SetPaneText(4, "Jigar");<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Sleep(1000);<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp; return 0;<br>}<br><br>And this thread is started from my dialog, <br><br>pBgThread = AfxBeginThread(threadBackgroundTask, this, THREAD_PRIORITY_NORMAL );<br><br>where I pass pointer to the dialog to the thread..<br><br>Now, the execution gives abort dialog while checking for ASSERT(this)..<br><br>So, does it mean that we can not access statusbar object from the global thread.. ?? I can not make the therad as the member of the class.. So, please suggest me the solution..<br><br><br>]]>
   </description>
   <pubDate>Fri, 25 Nov 2005 14:04:43 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9796&amp;title=how-to-apply-menus-xp-style-to-dialog#9796</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : Thanks,It helped me.. but still...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9794&amp;title=how-to-apply-menus-xp-style-to-dialog#9794</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1577">jigarmehtamscit</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 25 November 2005 at 12:15pm<br /><br />Thanks,<br><br>It helped me.. but still I am adding static control to the status bar.. <br><br>Because i took code from the sample application, there it was Indicator.. If I change anything in the default struct of the indicator, my program doesnt work properly..<br><br>Like if I change, <br><br>static UINT indicators&#091;&#093; =<br>{<br>&nbsp;&nbsp;&nbsp;  ID_SEPARATOR,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp ;&nbsp;&nbsp; // status line indicator<br>&nbsp;&nbsp;&nbsp; ID_INDICATOR_CAPS,<br>&nbsp;&nbsp;&nbsp; ID_INDICATOR_NUM,<br>&nbsp;&nbsp;&nbsp; ID_INDICATOR_SCRL,<br>};<br><br>to something like this,<br><br>static UINT indicators&#091;&#093; =<br>{<br>&nbsp;&nbsp;&nbsp;  ID_SEPARATOR,&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp ;&nbsp;&nbsp; // status line indicator<br>&nbsp;&nbsp;&nbsp; ID_MY_TEXT,<br>&nbsp;&nbsp;&nbsp; ID_INDICATOR_CAPS,<br>&nbsp;&nbsp;&nbsp; ID_INDICATOR_NUM,<br>&nbsp;&nbsp;&nbsp; ID_INDICATOR_SCRL,<br>};<br><br>Program doesnt work properly so, I add my static control to the status bar and doint what i want... so, how can I add the items in the status bar ?<br><br>]]>
   </description>
   <pubDate>Fri, 25 Nov 2005 12:15:00 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9794&amp;title=how-to-apply-menus-xp-style-to-dialog#9794</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : Why you need static text, if you...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9779&amp;title=how-to-apply-menus-xp-style-to-dialog#9779</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 25 November 2005 at 2:45am<br /><br /><P>Why you need static text, if you can update text directly to status bar</P><P>&nbsp;</P><P>m_wndStatusBar.SetPaneText(...) ?</P>]]>
   </description>
   <pubDate>Fri, 25 Nov 2005 02:45:19 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9779&amp;title=how-to-apply-menus-xp-style-to-dialog#9779</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : Oh.. again i was able to add teh...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9772&amp;title=how-to-apply-menus-xp-style-to-dialog#9772</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1577">jigarmehtamscit</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 24 November 2005 at 2:16pm<br /><br />Oh.. again i was able to add teh static control to the statusbar.. but it comes on teh menu bar..&nbsp;<img src="http://forum.codejock.com/smileys/smiley19.gif" border="0"><br><br>following is the code i wrote in initdialog function,<br><br>&nbsp;&nbsp;&nbsp; m_wndStatusBar.SetPaneInfo(0, ID_SEPARATOR, SBPS_STRETCH, 100);<br><br>&nbsp;&nbsp;&nbsp; int iIndex = m_wndStatusBar.GetPaneCount();<br>&nbsp;&nbsp;&nbsp; m_wndStatusBar.AddIndicator(IDC_STATIC1, iIndex);<br><br>&nbsp;&nbsp;&nbsp; int nIndex = m_wndStatusBar.CommandToIndex(IDC_STATIC1);<br>&nbsp;&nbsp;&nbsp; ASSERT (nIndex != -1);<br>&nbsp;&nbsp;&nbsp; m_wndStatusBar.SetPaneWidth(nIndex, 100);<br>&nbsp;&nbsp;&nbsp; m_wndStatusBar.SetPaneStyle(nIndex, m_wndStatusBar.GetPaneStyle(nIndex) | SBPS_NOBORDERS);<br>&nbsp;&nbsp;&nbsp; m_wndStatusBar.AddControl(&amp;m_XPos, IDC_STATIC1, FALSE);<br><br>i took one static control made a control variable for that as m_XPos and it shows the static control on menu bar.. instaead of statusbar..<br><br>Please tell me what can be the problem.. I tried all teh things.. I debugged then found that PositionBars function called from addcontrol function gets some -18 value for my control as X value.. so, it calculates the value on its own and MoveWindow function moves my window to the menu bar as a result.<br>]]>
   </description>
   <pubDate>Thu, 24 Nov 2005 14:16:46 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9772&amp;title=how-to-apply-menus-xp-style-to-dialog#9772</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : Oops..I got the sampel..But another...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9771&amp;title=how-to-apply-menus-xp-style-to-dialog#9771</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1577">jigarmehtamscit</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 24 November 2005 at 12:56pm<br /><br />Oops..<br><br>I got the sampel..<br><br>But another questiion is, I want to add a static text to the status bar.. Now, the value of the static text will be updated on runtime.. just like line number of the cursor or like the X and Y co-ordinate of the mouse.. So, how to add that to the status control ?? Any sample for that ? i saw the sample application statusbar but not found how to add the static text to status bar..<br><br>Thx<br>]]>
   </description>
   <pubDate>Thu, 24 Nov 2005 12:56:26 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9771&amp;title=how-to-apply-menus-xp-style-to-dialog#9771</guid>
  </item> 
  <item>
   <title><![CDATA[How to apply menus (xp style) to dialog ? : Hi,I want to apply office xp style...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9770&amp;title=how-to-apply-menus-xp-style-to-dialog#9770</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=1577">jigarmehtamscit</a><br /><strong>Subject:</strong> 3272<br /><strong>Posted:</strong> 24 November 2005 at 12:05pm<br /><br />Hi,<br><br>I want to apply office xp style menu to my dialog class.. So, how can i do that ? If i take code form the dialog, it gives error saying, GetCommandBars is not declared.. So, is there any sample of link from where i can find this.. ?<br><br>]]>
   </description>
   <pubDate>Thu, 24 Nov 2005 12:05:27 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=3272&amp;PID=9770&amp;title=how-to-apply-menus-xp-style-to-dialog#9770</guid>
  </item> 
 </channel>
</rss>