Reputation: 844
I'd like to use AutoIT's COM interface in a C# application to automate a window on a remote machine. I have code that looks like this:
var type = Type.GetTypeFromProgID("AutoItX3.Control", "my-remote-server", true);
var automater = (IAutoItX3) Activator.CreateInstance(type);
automater.DoStuff();
The problem is that the automater doesn't seem to be recognizing windows on the remote machine. Is there something I'm doing wrong? Is this even possible?
Upvotes: 1
Views: 1397
Reputation: 31
this will only work if your c# application is sitting on the same machine as the app you want to control. If you're using Remote Desktop, or Citrix etc, what you see on the screen is a bitmap of what the remote screen looks like, but when your C# app tries to find information about a window at certain coordinates, all there is is a bitmap. One way to make it work would be to have your c# app on the remote machine, and using file messages in a shared folder or other methods to give it remote instructions.
Upvotes: 1