Solved

listbox with more lines in each item

Posted on 1998-09-05
4
157 Views
Last Modified: 2013-11-20
Hi experts!
I would like to do a ListBox with several lines in each item, like this:
--------------------------
id:nnnn                  |
name: xxxxxxxxxxx        >  item 1
hobie: yyyyyyyyy         |    
--------------------------
id:nnnn                  |
name: xxxxxxxxxxx        >  item 2
hobie: yyyyyyyyy         |    
--------------------------

I tried using an AddString with "\n" and "\r" between strings, but it does not work. I have reviewed some multicolumn samples
but I need a diferent kind of viewing my data.

In addtion I new in MFC and need to do it on VC++ 1.52.
A big problem, don´t you think?
I would like some advice. please




0
Comment
Question by:jeeg
  • 2
  • 2
4 Comments
 
LVL 2

Accepted Solution

by:
prasanth earned 100 total points
ID: 1321770
You are going to have to do an owner drawn list box. Using "\n" or "\r" won't be of any help with AddString.

I'm pretty sure there is a owner-drawn listbox example that comes with VC1.5x called CTRLTEST that has a listbox which displays colored bars. Instead of filling in a colored box you will need to use DrawText or something similar to "paint" the lines for each item.
0
 

Author Comment

by:jeeg
ID: 1321771
prasanth
It Works!!!

Thank you very much...
All the best.

Hasta la vista AMIGO!!!
0
 
LVL 2

Expert Comment

by:prasanth
ID: 1321772
Great! Glad it helped.

If you "accept the answer" it'll be moved out of locked mode, so other people who might have the same problem can see the answer for a few points.
0
 

Author Comment

by:jeeg
ID: 1321773
thanks!!!
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

Suggested Solutions

Title # Comments Views Activity
ASCII Non-Printable characters/codes and their HTML equivalents 6 105
Line meaning 9 82
matchUp  challenge 9 94
mapAB Challlenge 35 127
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.

895 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

11 Experts available now in Live!

Get 1:1 Help Now