Software Archive
Read-only legacy content
17061 Discussions

problem with edit box & EM_LIMITTEXT

davidgraham
Beginner
511 Views
I have an edit box, I use EM_LIMITTEXT to limit the number of characters to 12.
I display a default value of 0.000 in the edit box.
I then find I have problems editing the edit box I can only replace the "0.000" with another 5 characters, I can not enter a number before the first "0".
If I remove the EM_LIMITTEXT message then the edit box works fine.

Am I doing something wrong?

Thanks,
David

iret=SendMessage(hMinE,EM_LIMITTEXT,12,0)
c13=' 0.000'c
iret=SendMessage(hMinE,WM_SETTEXT,0,loc(c13))
0 Kudos
0 Replies
Reply