Q:

Accelerator resource table giving errors

What's wrong with the following resource definition ?
ACCELERATOR_RESOURCE_ID ACCELERATORS
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
{
    VK_C, IDA_COPY, NOINVERT, CONTROL, VIRTKEY
    VK_V, IDA_PASTE, NOINVERT, CONTROL, VIRTKEY
    VK_A, IDA_SELECTALL, NOINVERT, CONTROL, VIRTKEY 
}

It gives me syntax error at the line VK_C, IDA_COPY, NOINVERT, CONTROL, VIRTKEY everytime I compile. And I can't pinpoint the problem.

A:

Virtual key identifiers for plain letters or numbers are not defined in Windows headers -- from WinUser.h:
/*
 * VK_0 - VK_9 are the same as ASCII '0' - '9' (0x30 - 0x39)
 * 0x40 : unassigned
 * VK_A - VK_Z are the same as ASCII 'A' - 'Z' (0x41 - 0x5A)
 */

Therefore the values VK_C, VK_V etc. are the problem.
Character constants like 'C' or 'V' are apparently not supported by the Resource Compiler and the practice seems to use (hex) numeric ASCII values instead:
0x43, IDA_COPY, NOINVERT, CONTROL, VIRTKEY
0x56, IDA_PASTE, NOINVERT, CONTROL, VIRTKEY
0x41, IDA_SELECTALL, NOINVERT, CONTROL, VIRTKEY 

