how to make your edit control accept only capital letters
-
Hi there, I wish to make my edit control accept only capital letters in combination with numbers. The member variable (m_confirmation_num) for that control is a CString with max characters of 5. That string later gets converted to a UINT conf_num. Initially m_confirmation is set to NULL and m_conf_num to 0. The edit control is defaulted to "00000" when the dialog box is first opened. With CAPS LOCK on or OFF, the edit control accepts only capital letters. This is what I want but why does it do that. This only happens with the following set up but for cases where I do not want the zeroes to display in the field, it accepts lowercase. Is there a way to make the edit control accept only capital letters? Or have the lowercase changed to uppercase upon user input? And is there a function that checks to see if a char is uppper or lowercase? Thanks.
-
Hi there, I wish to make my edit control accept only capital letters in combination with numbers. The member variable (m_confirmation_num) for that control is a CString with max characters of 5. That string later gets converted to a UINT conf_num. Initially m_confirmation is set to NULL and m_conf_num to 0. The edit control is defaulted to "00000" when the dialog box is first opened. With CAPS LOCK on or OFF, the edit control accepts only capital letters. This is what I want but why does it do that. This only happens with the following set up but for cases where I do not want the zeroes to display in the field, it accepts lowercase. Is there a way to make the edit control accept only capital letters? Or have the lowercase changed to uppercase upon user input? And is there a function that checks to see if a char is uppper or lowercase? Thanks.
-
Hi there, I wish to make my edit control accept only capital letters in combination with numbers. The member variable (m_confirmation_num) for that control is a CString with max characters of 5. That string later gets converted to a UINT conf_num. Initially m_confirmation is set to NULL and m_conf_num to 0. The edit control is defaulted to "00000" when the dialog box is first opened. With CAPS LOCK on or OFF, the edit control accepts only capital letters. This is what I want but why does it do that. This only happens with the following set up but for cases where I do not want the zeroes to display in the field, it accepts lowercase. Is there a way to make the edit control accept only capital letters? Or have the lowercase changed to uppercase upon user input? And is there a function that checks to see if a char is uppper or lowercase? Thanks.
-
Duh. I've looked at the properties but somehow overlooked it. Thanks a lot!
-
Hi there, I wish to make my edit control accept only capital letters in combination with numbers. The member variable (m_confirmation_num) for that control is a CString with max characters of 5. That string later gets converted to a UINT conf_num. Initially m_confirmation is set to NULL and m_conf_num to 0. The edit control is defaulted to "00000" when the dialog box is first opened. With CAPS LOCK on or OFF, the edit control accepts only capital letters. This is what I want but why does it do that. This only happens with the following set up but for cases where I do not want the zeroes to display in the field, it accepts lowercase. Is there a way to make the edit control accept only capital letters? Or have the lowercase changed to uppercase upon user input? And is there a function that checks to see if a char is uppper or lowercase? Thanks.
This is built-in:
ES_UPPERCASE
:)--Mike-- Visual C++ MVP :cool: LINKS~! Ericahist | PimpFish | CP SearchBar v3.0 | C++ Forum FAQ