Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

How do I update my ListBox or window?

Posted on 1999-07-04
3
Medium Priority
?
213 Views
Last Modified: 2010-04-16
I want to update my listbox or is it the window I have to update. How do I do that ?
Thanks!
0
Comment
Question by:bert1
[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
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
JensUniweb earned 30 total points
ID: 1199113
The list box has a handle. In plain windows you just do InvalidateRect( handle,NULL,true ); This tells the system that the listbox needs to redraw. And to force this you can do a UpdateWindow( handle ).

Maybe this was not what you meant. But I hope soo.

 Jens Yllman
0
 

Author Comment

by:bert1
ID: 1199114
Yes it worked with GetHandle(); UpdateWindow();

But my window unaccessable when I add strings to the ListBox. What do I need to do, to be able to move the window while the program are adding string to the listbox?

It says program not responding when it add strings. But it's ok when the program has finished adding strings.
0
 
LVL 2

Expert Comment

by:JensUniweb
ID: 1199115
I'm not sure I understand what you mean. Have you created the ListBox with CreateWindow()??? If so you have the handle to the listbox. Then use that handle.

Maybe you have the listbox in a dialogbox where you don't create the listbox. You can still get the handle for the listbox.

Anyway, I'm not sure I know what you're trying to do.

 Jens Yllman
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

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…
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 viewer will learn how to clear a vector as well as how to detect empty vectors in C++.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

715 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