QUOTE (victorpiper @ Mar 16 2007, 05:21 PM)
Hi, (I know this is an old thread)
Having spent many hours trying to make SendInput work, I'm happy to find the solution here - to set cbSize to 28, instead of 20, the actual size of the KEYBDINPUT INPUT structure. Like Victor, I also wondered why 28 instead of 20, and expect it's because the INPUT structure is a union of three structures, and the size of INPUT is being determined by the largest structure in the union, which is the MOUSEINPUT structure.
Belated THANKS! to COSMIN and Victor