I need to automate a client's old legacy code without touching it. This requires human input to press F17
and I want to include that key press in a longer process using Windows Forms's SendKey.Send
Method to press the button. A problem arises: SendKeys.Send
only supports function keys up to F16
.
Looking at the source code, adding the KeywordVk
for F17
at line 68 would solve the problem, but I cannot touch the .NET source code, nor inherit the class (due to the private constructor) or make a custom version of it (due to Interop not being importable).