Solved

creating status windows

Posted on 1998-08-19
3
279 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say 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

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn how to pass data into a function in C++. This is one step further in using functions. Instead of only printing text onto the console, the function will be able to perform calculations with argumentents given by the user.

628 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