Hi All
Im sure i am missing something really obvious here
But i have hunted high and low an the net and cannot solve this simple question
Using
SendMessage(GetDlgItem(g_hwnd,IDC_GENERAL_ENTRYBOX),EM_REPLACESEL ,(WPARAM)TRUE,(LPARAM)L"replacewith");
works fine when i want to insert at the caret or delete selection and insert another character
but what do i send in the !,(LPARAM)L"replacewith"!
to delete the last character
having tried all manner of "\?" characters
my last attempt was to try
SendMessage(GetDlgItem(g_hwnd,IDC_GENERAL_ENTRYBOX),EM_SETSEL ,(WPARAM)end,(LPARAM)end);
SendMessage((GetDlgItem(g_hwnd, IDC_GENERAL_ENTRYBOX)),WM_CLEAR,0,0);
that did not work either
Any help would be appreciated Thanks
This seems to work.
txtlen = SendMessage(GetDlgItem(hwndDlg, 4002), WM_GETTEXTLENGTH, 0, 0);
SendMessage(GetDlgItem(hwndDlg, 4002), EM_SETSEL, txtlen-1, txtlen);
SendMessage(GetDlgItem(hwndDlg, 4002), EM_REPLACESEL, TRUE, (LPARAM)"");
John
:-[
Indeed it does
I am sending soft button pentaps to this edit box and not keypresses
I was losing focus to the said editbox and not doing it right at all
Big Thanks John