Click here to Skip to main content
16,019,140 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: How to change the font-color in Edit Control? Pin
Hamid Taebi22-Aug-06 20:07
professionalHamid Taebi22-Aug-06 20:07 
QuestionHow can i color to Splitter Pin
kiranin22-Aug-06 20:02
kiranin22-Aug-06 20:02 
AnswerRe: How can i color to Splitter Pin
sujtha22-Aug-06 20:49
sujtha22-Aug-06 20:49 
QuestionHow to validate the special characters Pin
reddy harish22-Aug-06 19:35
reddy harish22-Aug-06 19:35 
AnswerRe: How to validate the special characters Pin
Waldermort22-Aug-06 19:43
Waldermort22-Aug-06 19:43 
GeneralRe: How to validate the special characters Pin
Stephen Hewitt22-Aug-06 20:25
Stephen Hewitt22-Aug-06 20:25 
GeneralRe: How to validate the special characters Pin
Waldermort22-Aug-06 20:42
Waldermort22-Aug-06 20:42 
AnswerRe: How to validate the special characters [modified] Pin
Cedric Moonen22-Aug-06 20:31
Cedric Moonen22-Aug-06 20:31 
reddy harish wrote:
user has to enter the file name


How does he enter the characters ? If it is in a edit box, then I would go for overriding the control. You override the OnChar function, and check first if it the character entered is a valid one (if ( (NewChar>'a') && (NewChar<'z') ), of course you have to check for upper case characters also). If the character is valid, then you can call the OnChar function from the base class. If not, don't call the function and the character will never appear in the edit box. This is nicer than validatating the string after inserting all the data.


-- modified at 2:31 Wednesday 23rd August, 2006

BTW, did asked a question yesterday about file validating also ? Did you look at the answer of Christian Chraus ? About the CFileDialog[^]? It is in general the way to go when you want the user to open a file. And it is much more user friendly than having the user to enter the complete file or path.


Cédric Moonen
Software developer

Charting control [Updated - v1.1]

GeneralRe: How to validate the special characters Pin
reddy harish22-Aug-06 21:02
reddy harish22-Aug-06 21:02 
GeneralRe: How to validate the special characters Pin
reddy harish23-Aug-06 3:08
reddy harish23-Aug-06 3:08 
QuestionIcons Pin
Waldermort22-Aug-06 19:27
Waldermort22-Aug-06 19:27 
AnswerRe: Icons Pin
Rage22-Aug-06 21:59
professionalRage22-Aug-06 21:59 
GeneralRe: Icons Pin
Waldermort22-Aug-06 23:54
Waldermort22-Aug-06 23:54 
GeneralRe: Icons Pin
Rage23-Aug-06 0:09
professionalRage23-Aug-06 0:09 
GeneralRe: Icons Pin
Waldermort23-Aug-06 2:32
Waldermort23-Aug-06 2:32 
GeneralRe: Icons Pin
Waldermort23-Aug-06 7:47
Waldermort23-Aug-06 7:47 
QuestionMinimize button pressed event Pin
Kiran Pinjala22-Aug-06 19:24
Kiran Pinjala22-Aug-06 19:24 
AnswerRe: Minimize button pressed event Pin
prasad_som22-Aug-06 19:29
prasad_som22-Aug-06 19:29 
AnswerRe: Minimize button pressed event Pin
Waldermort22-Aug-06 19:30
Waldermort22-Aug-06 19:30 
GeneralRe: Minimize button pressed event Pin
Kiran Pinjala22-Aug-06 19:54
Kiran Pinjala22-Aug-06 19:54 
AnswerRe: Minimize button pressed event Pin
Hamid Taebi22-Aug-06 20:17
professionalHamid Taebi22-Aug-06 20:17 
GeneralRe: Minimize button pressed event Pin
Waldermort22-Aug-06 20:39
Waldermort22-Aug-06 20:39 
QuestionNeed help Urgent Pin
reddy harish22-Aug-06 18:50
reddy harish22-Aug-06 18:50 
AnswerRe: Need help Urgent Pin
Christian Graus22-Aug-06 18:56
protectorChristian Graus22-Aug-06 18:56 
AnswerRe: Need help Urgent Pin
_AnsHUMAN_ 22-Aug-06 19:02
_AnsHUMAN_ 22-Aug-06 19:02 

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.