Re: ctrl+V in CComboBox
Yes you will need to call TranslateAccelerator from within
PreTranslateMessage.
The only difference between using an Accelerator table and handling the
shortcut in PreTranslateMessage is that when/if new accelerator keys need to
be added, you don't have to mess with PreTranslateMessage anymore.
I personally think it is cleaner to use accelerator tables.
AliR.
"Ajay Kalra" <ajaykalra@yahoo.com> wrote in message
news:92d1ca66-7dd6-4e69-9f9f-8da03e86ca5e@z66g2000hsc.googlegroups.com...
On Aug 28, 3:04 pm, "AliR \(VC++ MVP\)" <A...@online.nospam> wrote:
Or setup and accelerator table and use it in the combobox class.
You still need to deal with PreTranslateMessage. Correct?
--
Ajay
Shift+Insert, Ctrl+Insert and Shift+Delete will work without any code, but
Ctrl+V Ctrl+C are not built in.
AliR.
"Ajay Kalra" <ajayka...@yahoo.com> wrote in message
news:718acec7-d0c2-4ac6-9f8b-df126760497f@25g2000hsx.googlegroups.com...
On Aug 28, 9:18 am, Kuenga <sagku...@gmail.com> wrote:
Hi,
I have used a CCombox in a toolbar. In the ccombox, when I do right
click, I get menu show Copy, cut and paste etc in the context menu. No
code written for it.
But thru keyboard when I do Ctrl+V, CTrl+C, nothing happens. How to
set this keyboard option also automatically ?
When MFC provided cut, copy and paste automaticcaly on Context Menu in
CCombox why it is not accepting keyboard shortcuts ?
Thanks
Try handling the keyboard combination in PreTranslateMessage of the
combobox.
--
Ajay