0

I have an executable written in C# running on Windows Server 2012 r2

If I start it, when I am working on the physical computer, it works just fine. But if I am logged into the computer through RDP it fails with the following error: enter image description here

The program is supposed to listen for some events from a HID device.

Ali Syed
  • 161
  • 1
  • 2
  • 8
  • 1
    I bet I know! When you connect via RDP, by default the system will map things like your printer, potentially your sound device, even things like smart card readers and other USB things back to the machine you're connecting from. Just guessing, but it seems likely your HID device isn't being detected because of this. To check, run mstsc.exe and go into the options\local resources. – Mark Allen Oct 17 '14 at 23:43
  • @MarkAllen the thing is, the program doesn't crash if the device is not connected. In fact, it never crashes if it is run when physically on the machine! – Ali Syed Oct 17 '14 at 23:51
  • 1
    Well, the other part is that it also likes to redirect your sound system. For example if I'm using Windows Media Player to listen to a podcast at work today and then tomorrow I work from home and connect to the machine via RDP, Windows Media Player immediately throws up an error when I connect, claiming that the "media has changed". VLC on the other hand doesn't care, but I digress. Try disabling audio redirection. – Mark Allen Oct 21 '14 at 19:19

0 Answers0