Try if this will work...
[DllImport("coredll.dll")]
static extern void keybd_event(byte bVk, byte bScan, int dwFlags, int
dwExtraInfo);
const int KEYEVENTF_KEYPRESS = 0x0000;
const int KEYEVENTF_KEYUP = 0x0002;
void SendKey(Keys key) {
keybd_event((byte)key, 0, KEYEVENTF_KEYPRESS, 0); // key press
keybd_event((byte)key, 0, KEYEVENTF_KEYUP, 0); // key release
(KEYEVENTF_KEYUP)
}
void EndCall() {
SendKey(Keys.F4);
}
Call EndCall() in your reject call logic...