Solved

CEdit cut,paste etc. abilities

Posted on 2001-06-19
4
375 Views
Last Modified: 2013-11-20
Hi,
I created a CEdit Ctrl which its parent is the view:

void CIrisGUITestsView::OnCreateedit()
{
     CEdit* mEdit = new CEdit();
     CRect aEditRect(CPoint(10,10),CPoint(150,35));
     mEdit->Create (WS_BORDER | WS_CHILD |ES_AUTOHSCROLL|WS_EX_LTRREADING  ,aEditRect,this,0);
     mEdit->ShowWindow (SW_SHOW);          
}
when I tried to use copy & paste abilities of the CEdit Ctrl it does not working.
I found out that the same code is working when the parent is a dialog box...

Can someone please help me with this matter ??
thanks,
Iris.
0
Comment
Question by:irisz
  • 3
4 Comments
 
LVL 9

Expert Comment

by:Pacman
ID: 6206006
What about using CFormView ?
0
 

Author Comment

by:irisz
ID: 6206025
I am not using a CFormView.
Besides, in my real app the parent of the CEdit is a CWnd and not a CView. I think that the problem occurs because that the parent of the Edit is not a dialog.
0
 
LVL 9

Accepted Solution

by:
Pacman earned 25 total points
ID: 6206049
The Window Procedure of the CDialog class handles the controls. If you add controls to a CWnd then you'll have no "control support". If you want this support in your CWnd then you've to create a CFormView in it and add the controls to the CFormView object.
0
 
LVL 9

Expert Comment

by:Pacman
ID: 6213927
do you have any questions?
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
countEvens challenge 2 101
FizzBuzz challenge 9 81
Line meaning 9 86
sumHeights2  challenge 7 105
Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
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.

809 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