Jump to content
Sign in to follow this  
n4gix

XML problem in FSX ??

Recommended Posts

Hi experts,A question (or warning ?) for you.......In all my XML gauges for FS9 I use simple constructions like:(A:SIM ON GROUND,bool)SPBRKWhich works without any problem.Iow: print a string or not, based on a certain condition.Now, in FSX this code doesn't work properly.- If I load the 2D-panel (in Windowed mode) sometimes the string will be displayed when appropriate, sometimes it won't. Usually the first section in the gauge that does this, works, and the next sections with the same construction don't.- And if it doesn't, switching to Fullscreen mode, suddenly displays the string correctly (but not always).- And when switching to Fullscreen mode solved it, after switching back to Windowed mode it works normally for the rest of the flight.Now, if I code it like this:(A:SIM ON GROUND,bool)SPBRK(so: pack the string printing in a nested element) the problem is entirely gone.Weird ???Or can someone explain why the first code is wrong ?Cheers, Rob Barendregt

Share this post


Link to post
Share on other sites

>Hi experts,>>A question (or warning ?) for you.......-SNIP->Weird ???>>Or can someone explain why the first code is wrong ?>>Cheers, Rob Barendregt>The new Aces XML is weird to begin with and perhaps theparser is different now for the old, reliable XML.In any case, it may be because the "new" Aces format isso overly BLOATED and your initial code is NOT :)Sorry I have no real answer to your question. Paul


Wide-5.jpg

Share this post


Link to post
Share on other sites

Rob,I wish I knew, and just to support what Paul said, it's probably got something to do with the new syntax . Who KNOWS what subtle perfectly legit structures are broken.If I were you, and this may not be the most efficient way to handle it, but probably the most reliable, I'd put the conditional inside the string:%((L:condition, bool))%{if}%BLOATME%{end}--Jon

Share this post


Link to post
Share on other sites

Well, I'll just accept it as it is then :-)I need to clean up some of the old gauges code anyway...Cheers, Rob

Share this post


Link to post
Share on other sites
Guest lilo

Rob,I had similar problems with my old gauge when testing it under FSX. Some text was displayed, some not and couldn't figure it out. Finally I rebuilt it using the new XML schema. I started with the ACE.tool to get the mail schema, then I partially worked in UltraEdit32 for copy and paste operations and in ACE to add new elements.A also guess that the new XML parser is not 100 % compliant to the parser used in FS9.rgdslilo

Share this post


Link to post
Share on other sites

>A also guess that the new XML parser is not 100 % compliant to>the parser used in FS9.Actually, it is the other way around. The old parsing engine is rather loosey-goosey and not nearly as strict.There are some things one could "get away with" in FS9 that FSX will not permit... ;)


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

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
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...