Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

how to display multi-lines in a dialog box using VC

Posted on 1998-11-19
3
Medium Priority
?
190 Views
Last Modified: 2010-04-01
I'm trying to display some string in a dialog box. I use the
 CString variable and UpdateData(FALSE) to do it. But I can not get multiple lines out. They are all in one line.
0
Comment
Question by:f22
[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 6

Expert Comment

by:thresher_shark
ID: 1178254
Since it looks like you're using MFC and Visual C++, do the following:

- Open the dialog for editing in the resource editor
- Right click on the troublesome edit box
- Go to properties
- Go to one of the other tabs (something like More Styles) and select "multiple lines"
- Recompile

It should work now.  If you have any further questions, please feel free to ask.
0
 
LVL 15

Accepted Solution

by:
Tommy Hui earned 300 total points
ID: 1178255
You will need to make sure that your lines are separated by \r\n and NOT \n\r.

The edit control will only use \r\n as the line separator.
0
 
LVL 6

Expert Comment

by:thresher_shark
ID: 1178256
Wouldn't that be better posted as comment?
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

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

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
Suggested Courses

636 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