Solved

Text Area In MFC and Win32

Posted on 2001-09-02
7
1,186 Views
Last Modified: 2013-11-20
I was wondering how can I add a text area control into a dialog based application by using mfc and win32 approached ?I don't see any text area control in the resource editor tool.

text area - the area that can display text and will have scroll bar when the area is full of text)
0
Comment
Question by:yccheok
[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
7 Comments
 
LVL 2

Accepted Solution

by:
xu2000 earned 50 total points
ID: 6449637
Hi,
Why not EditBox?
Set Stytle: check Multiline and uncheck AutoHscoll and check VerticalScoll

Xu
0
 
LVL 3

Expert Comment

by:kulina
ID: 6449639
It's called Edit Box in VC++. Click on that  ab| button on controls grid. Draw the edit box on the dialog. Select it, right click and select "Properties". Under "Styles" check "Multiline". Hope this helps.
0
 

Author Comment

by:yccheok
ID: 6475706
This help. However, i was wondering how do i add text to the edit box since every time the box can only display one line of text ?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 3

Expert Comment

by:kulina
ID: 6475719
>>Under "Styles" check "Multiline"
0
 

Author Comment

by:yccheok
ID: 6481434
I already did that but don't know what function can used to add multiline :
I have a edit control  (I am using c/sdk) which i tend to make it as text area to display my program message. the control has properties as:
vertical scroll, auto vscroll, want return.

I was wondering how can i add text in multiple line. for instance, i use
char *buf1 = "hello\r\n";
char *buf2 = "hai\r\n";
SendMessage(GetDlgItem(hDlg, IDC_CON_CON), WM_SETTEXT, 0, (LPARAM) buf1);

SendMessage(GetDlgItem(hDlg, IDC_CON_CON), WM_SETTEXT, 0, (LPARAM) buf2);

it can only display
hai

where i want
hello
hai


Pls help. If possible, do e-mail the solution to my mail box
yccheok@yahoo.com

since i don't have any internet access in this few day and it may take my sometimes to search back my message :)

thanks

regards
yccheok

0
 
LVL 23

Expert Comment

by:Roshan Davis
ID: 9531980
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Answered by: xu2000

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

Roshan Davis
EE Cleanup Volunteer
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
while loop over for loop 7 119
building a service to accessed via telnet client, want colors ? 4 106
Annoying "thing" blocks my view 4 145
wordmultiple challenge 12 169
Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
Introduction: Dialogs (1) modal - maintaining the database. Continuing from the ninth article about sudoku.   You might have heard of modal and modeless dialogs.  Here with this Sudoku application will we use one of each type: a modal dialog …
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.
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

732 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