Blocking cut, copy, paste and context menu for an edit control!

Sometimes you may have to prevent cut, copy, and paste, sometimes context menu too, on an edit control. So how to do this! Well it’s easy to do this… Override WindowProc and provide empty case statements for these events, WM_COPY, WM_CUT, WM_PASTE, WM_CONTEXTMENU. [sourcecode language=’cpp’]LRESULT CMyEdit::WindowProc(UINT Message, WPARAM wParam, LPARAM lParam) {    switch( Message ) […]
Continue reading…