![]() |
SetEditStyle(ES_NUMBER) = no effect |
Post Reply
|
| Author | |
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Topic: SetEditStyle(ES_NUMBER) = no effectPosted: 22 April 2009 at 6:28pm |
|
XTP 13.
Consider this:
pControlEdit->SetEditStyle(pControlEdit->GetEditStyle() | ES_NUMBER);
ES_NUMBER has no effect!
BOOL CXTPCommandBarEditCtrl::CreateEdit(DWORD dwStyle, CWnd* pParentWnd)
{ if (GetRichEditContext().m_hInstance) { // Please add this to start with:
ASSERT((dwStyle & (all CEdit-only styles)) == 0);
BOOL bResult = CWnd::Create(GetRichEditContext().m_strClassName, 0, dwStyle, CRect(0, 0, 0, 0), pParentWnd, 0); SendMessage(EM_SETEVENTMASK, 0, ENM_CHANGE); SendMessage(EM_SETTEXTMODE, TM_PLAINTEXT | TM_SINGLELEVELUNDO); return bResult; return Create(dwStyle, CRect(0, 0, 0, 0), pParentWnd, 0); Secondly, it seems I cannot explicitly use CEdit here. That's bad... (I don't want to override the control for such a small thing!)
|
|
|
PokerMemento - http://www.pokermemento.com/
|
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 23 April 2009 at 2:43am |
|
Hi,
The thing that our Edit in CommandBars is actually RichEdit - but it doesn't support ES_NUMBER style :(
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 23 April 2009 at 3:08am |
|
Yes, so please add the ASSERT above. You should check for ES_NUMBER, ES_PASSWORD etc...
But, I still think it should be possible to explicitly use CEdit where needed!
|
|
|
PokerMemento - http://www.pokermemento.com/
|
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |