-
December 16th, 2013, 07:29 AM
#1
How to create an edit box in a CView
I'm trying to create an edit box in a CView.
So far, this is how far I've gotten:
With this code
Code:
// .h
CEdit m_MyEditField;
// .c
m_MyEditField.Create(WS_CHILD | WS_VISIBLE,CRect(40,40,500,Y+55),this,0x1552);
m_MyEditField.SetWindowText("this is my CEdit field");
As you can see, the edit box doesn't look like the ones in a dialog, which is what I'm trying to accomplish.
Is there possibly some other class I should be using for the edit box?
Or another setting for .Create?
-
December 16th, 2013, 08:04 AM
#2
Re: How to create an edit box in a CView
Sounds like you want a CFormView.
-
December 16th, 2013, 09:57 AM
#3
Re: How to create an edit box in a CView
...or directly use CEditView class, derived from CView, which contains an edit control itself.
Also have a look at this FAQ: How to make a simple text editor?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|