Cancel Flight Plan from SimConnect

Discuss on the SimConnect SDK can be used by programmers to write add-on components for Prepar3D
Post Reply
Fredo0709
Posts: 3
Joined: Tue Apr 28, 2015 4:11 pm

Cancel Flight Plan from SimConnect

Post by Fredo0709 »

Hi,

I tried looking for the answer but so far I haven't been able to find one.

Does anyone know how to cancel an existing flight plan from SimConnect? So far we use SimConnect's scenario function SimConnect_FlightPlanLoad to load a flight plan but if the user wants to cancel, we want to be able to do so from SimConnect as well.

Thanks,
Austin
FSTramp
Posts: 78
Joined: Tue Oct 06, 2015 12:12 pm

Re: Cancel Flight Plan from SimConnect

Post by FSTramp »

NULL
Fredo0709
Posts: 3
Joined: Tue Apr 28, 2015 4:11 pm

Re: Cancel Flight Plan from SimConnect

Post by Fredo0709 »

Hi,

Thanks for your reply. Do you mean load in a NULL file? Can I trouble you with an example?

Is it like this?

HRESULT SimConnect_FlightPlanLoadW(
HANDLE hSimConnect,
const wchar_t* szFileName
);

where szFileName is set to NULL?

Thanks,
Austin
BenBaron
Posts: 80
Joined: Fri Jan 16, 2015 7:51 am

Re: Cancel Flight Plan from SimConnect

Post by BenBaron »

Hi Fredo,

I guess this is indeed what he meant...easiest way would be to just try it out...pass in a nullptr as szFileName and see what happens :).

Greets,

Benny
Fredo0709
Posts: 3
Joined: Tue Apr 28, 2015 4:11 pm

Re: Cancel Flight Plan from SimConnect

Post by Fredo0709 »

Hi,

We just did and I'm happy to report back that it did indeed work.

Thanks everyone!
Austin
Post Reply