Solved

How do you get a CListBox to wrap?

Posted on 2011-02-28
3
492 Views
Last Modified: 2012-05-11
Hello,

I have a CListBox that I need to have the text wrap, instead of disappearing at the edge.

I've tried enabling the scrollbars, etc - nothing seems to work.

Seems like this should be pretty simple, but so far I just haven't had any luck.

Any suggestions would be GREATLY appreciated!!!
0
Comment
Question by:tmitch68
3 Comments
 
LVL 29

Expert Comment

by:Paul Jackson
ID: 35003534
0
 
LVL 33

Accepted Solution

by:
sarabande earned 250 total points
ID: 35004667
a listbox cannot make automatic text wrap. you would need to do the wrap yourself and create additional lines when the text doesn't fit into a line.

you may try alternatively a multiline CEdit in read-only mode. it pretty good can wrapping. or i mean to remember that a multiline CStatic also wraps (but am not sure).

Sara
0
 

Assisted Solution

by:cehopkins
cehopkins earned 250 total points
ID: 35010602
You could use a CRichEdit box with the Multiline property set to True.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

863 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now