Click here to Skip to main content
15,897,334 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Menu in SDI Application Pin
zahid_ash2-Mar-05 3:12
zahid_ash2-Mar-05 3:12 
GeneralRe: Menu in SDI Application Pin
David Crow2-Mar-05 3:24
David Crow2-Mar-05 3:24 
GeneralRe: Menu in SDI Application Pin
Maximilien2-Mar-05 3:27
Maximilien2-Mar-05 3:27 
Generalsave xml atributtes by c++ Pin
mikelman2-Mar-05 0:58
mikelman2-Mar-05 0:58 
GeneralRe: save xml atributtes by c++ Pin
ThatsAlok2-Mar-05 17:28
ThatsAlok2-Mar-05 17:28 
QuestionHow to create a CEdit derived class Pin
misturas2-Mar-05 0:50
misturas2-Mar-05 0:50 
AnswerRe: How to create a CEdit derived class Pin
Jetli Jerry2-Mar-05 1:30
Jetli Jerry2-Mar-05 1:30 
AnswerRe: How to create a CEdit derived class Pin
Cedric Moonen2-Mar-05 1:33
Cedric Moonen2-Mar-05 1:33 
Hi,

It is quite simpe to do: with Class Wizard, create your own class (call it CMyEdit for example) and make it inherits from CEdit. Then override the OnChar method (not 100% sure about the function name but I think this is good). In this function, compare the char entered with those in your list. If it is not allowed, don't call OnChar from the parent (CEdit::OnChar() ). Otherwise call it and it will add the char in the edit box.

You will probably need to add a function to send your list to the class also. Call this function in the initalisation of your dialog box that contains your edit control.

Now, to add your specific control, use the resource editor and paste a standard edit, and with class wizard, you will have the possibility to choose your class to be associated with the control.

That's it
Hope this helps
AnswerRe: How to create a CEdit derived class Pin
misturas2-Mar-05 2:22
misturas2-Mar-05 2:22 
GeneralRe: How to create a CEdit derived class Pin
PJ Arends2-Mar-05 6:31
professionalPJ Arends2-Mar-05 6:31 
Generaladd a button on Save As dialogue tool bar Pin
MihaiChioariu2-Mar-05 0:42
MihaiChioariu2-Mar-05 0:42 
Questionhow to draw the resizing dialog border? Pin
lowiq2-Mar-05 0:34
lowiq2-Mar-05 0:34 
GeneralKeystate of mutliple keys like LAlt+Tab Pin
vidhyas2-Mar-05 0:28
vidhyas2-Mar-05 0:28 
GeneralRe: Keystate of mutliple keys like LAlt+Tab Pin
Blake Miller2-Mar-05 8:47
Blake Miller2-Mar-05 8:47 
QuestionHow to upload file Pin
Mayank Goyal2-Mar-05 0:25
Mayank Goyal2-Mar-05 0:25 
AnswerRe: How to upload file Pin
ThatsAlok2-Mar-05 2:29
ThatsAlok2-Mar-05 2:29 
GeneralRe: How to upload file Pin
Mayank Goyal2-Mar-05 16:06
Mayank Goyal2-Mar-05 16:06 
GeneralRe: How to upload file Pin
ThatsAlok2-Mar-05 17:38
ThatsAlok2-Mar-05 17:38 
GeneralJust one document open at the same time Pin
senn2-Mar-05 0:18
senn2-Mar-05 0:18 
GeneralRe: Just one document open at the same time Pin
David Crow2-Mar-05 2:26
David Crow2-Mar-05 2:26 
GeneralRe: Just one document open at the same time Pin
senn2-Mar-05 2:37
senn2-Mar-05 2:37 
GeneralRe: Just one document open at the same time Pin
David Crow2-Mar-05 2:56
David Crow2-Mar-05 2:56 
GeneralRe: Just one document open at the same time Pin
senn2-Mar-05 3:16
senn2-Mar-05 3:16 
GeneralRe: Just one document open at the same time Pin
David Crow2-Mar-05 8:31
David Crow2-Mar-05 8:31 
GeneralRe: Just one document open at the same time Pin
senn2-Mar-05 19:47
senn2-Mar-05 19:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.