Click here to Skip to main content
13,510,146 members
Rate this:
Please Sign up or sign in to vote.
I'm a new bee to MFC.

I'm trying to do a simple MFC dialog base project. This project involves multiple text boxes. So my question is "Is it possible to have multiple rich edit control in a single dialog. So if possible how can i create a pointer to it?
Similar to this:
CEdit* e;
Posted 6-Sep-12 1:15am
Updated 6-Sep-12 6:53am
__John_ 6-Sep-12 8:07am
I cant think of any reason why you cant have more than one rich edit control.
The code you posted looks fine.
What error are you getting, where do you hit a problem?
Sharath2790 6-Sep-12 20:45pm
that code for simple edit control!!!

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Yes, you will have to do something like :

CRichEditCtrl* edit1 = dynamic_cast<CRichEditCtrl*>( GetDlgItem(IDC_RICHEDIT21 ));

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web04 | 2.8.180417.1 | Last Updated 6 Sep 2012
Copyright © CodeProject, 1999-2018
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100