Solved

StatusBar Pane lengths

Posted on 1998-10-29
2
789 Views
Last Modified: 2013-12-03
I have a status bar with indicators as shown

static UINT indicators[] =
{
      ID_SEPARATOR,           // status line indicator
      ID_SEPARATOR,
      ID_SEPARATOR
};


My problem is that each Pane is way to long.
The 3rd pane cant even be seen unless I resize the window.

Is there anyway to cahgne the size of statusBar Panes?

I would like the pane layout to be like this
Pane 1 50% of satus bar length
Pane 2 25% of status bar length
Pane 3 25% of status bar length

+------------------------+------------+------------+
|Pane 1                  |  Pane 2    |  Pane 3    |
+------------------------+------------+------------+
0
Comment
Question by:vinny5
2 Comments
 

Accepted Solution

by:
ddeboskey earned 100 total points
ID: 1415682
CStatusBar has a member function SetPaneInfo
which takes the following arguments:

void SetPaneInfo( int nIndex, UINT nID, UINT nStyle, int cxWidth );

Parameters
nIndex   Index of the indicator pane whose style is to be set.
nID   New ID for the indicator pane.
nStyle   New style for the indicator pane.
cxWidth   New width for the indicator pane.

Since you can readily obtain the width of the status bar using the GetWindowRect function, obtaining the size fractions you need should be easy arithmetic.

I hope this helps.
0
 

Author Comment

by:vinny5
ID: 1415683
thanks
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
link access with Quickbooks 9 67
Windows Installer 4 76
"Video DataSource is Offline or not responding"  - why? 1 117
Visual Studio hangs on running project 6 59
This article describes how to add a user-defined command button to the Windows 7 Explorer toolbar.  In the previous article (http://www.experts-exchange.com/A_2172.html), we saw how to put the Delete button back there where it belongs.  "Delete" is …
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question