Jump to content
The simFlight Network Forums

Recommended Posts

Posted

Hey!

 

Im using this FSUIPC Client DLL for a while now and i have to say: BRILLIANT :)

 

Yesterday i found your 3.0 BETA Version of the client...

 

Cause I wanted to send a keypress to Prepar3D, I used the new function:

FSUIPCConnection.SendKeyToFS(Keys.K, SendModifierKeys.Control, Me)

...im writing in vb...

 

The code works perfectly in FSX, but in Prepar3D simply nothing happens. But there is no error though...

 

Does anybody have an idea, why it doesnt work in Prepar3D?

 

Thanks,

Philipp

Posted

Hi Philipp,

 

I don't have P3D so I can't test anything here.

 

To receive key presses, FSX or P3D must have focus. When you send keys with FSUIPCConnection.SendKeyToFS, the DLL brings the sim into focus using an FSUIPC control called 'Key focus restore'.

 

It may be that this doesn't work for P3D. Can you just try this out for me and report back? All you need to do is run this line of code from a button or similar:

FSUIPCConnection.SendControlToFS(FSUIPCControl.Key_focus_restore, 0)

If it's working then your application will lose focus and FSX/P3D will get the focus.

 

Depending on the results I'll see if there's anything that can be done.

 

Regards,

 

Paul

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.