Solved

creating status windows

Posted on 1998-08-19
3
272 Views
Last Modified: 2010-04-10
I need to create four status windows.  How do I create the status window in where I  can write information to any specific windows and also clear that window of any text it may have?
0
Comment
Question by:cmenter
3 Comments
 
LVL 22

Expert Comment

by:nietod
ID: 1170703
Is this for MFC?  I believe there are status bar windows for that purpose.  

Otherwise, just use an ordinary static text control window.  (That is, just specify "STATIC" for the window class when you create the window.)  You can then use SetWindowText() and GetWindowText() to set and get the messages in the window.
0
 
LVL 1

Expert Comment

by:bsimser
ID: 1170704
You need to clarify your question. Is this for MFC? BCB? Is it a GUI app or a text app? Like nietod said, you can create as many windows as you want and use SetWindowText() to set the text. I think it would be better to have a listbox if you're using a GUI and add items to it since then you can scroll through them, insert items, etc. More info about what you're trying to do would be good.
0
 

Accepted Solution

by:
TpB earned 100 total points
ID: 1170705
hStsWnd = CreateStatusWindow( WS_CHILD | WS_VISIBLE | CCS_BOTTOM | SBARS_SIZEGRIP, lpszTitle, hParentWnd, hMenuID );

Set lpszTitle to the text you want, and change it with... the messages with

SendMessage( hStsWnd, WM_SETTEXT, 0, lpTitle );
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone 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

Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

861 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