Jump to content
Sign in to follow this  
Alba

Re. Total fuel gauge

Recommended Posts

Guys, I just can't see what's wrong here.I have tried various options to code this small gauge. I have opened it in Internet Explorer ok. It shows no errors in XMLSpy. I have as you can see changed the variable to one that is in the tutorial but still it refuses to display the text string.The background bmp displays on the popup window ok. So the gauge is opening but the text string does not. I have tried changing the position values in case they were wrong but still nothing. The X="110" Y="4" are taken from the top left of the gauge background bmp. I am assuming that is correct from what I have gathered from the tutorial.Could someone take a look at the code and see what I have done wrong?It's driving me nuts!! I know that most of you will have been going nuts at some point but this is not a complex thing here and I am following the tutorial as I see it but I am doing something wrong.%((A:GPS WP NEXT ID, string))%!s!Thanks.Regards...Kenny

Share this post


Link to post
Share on other sites

Kenny, Try with .Close always with and use caps for the tokens (Element,Text,Image,etc)Tom

Share this post


Link to post
Share on other sites

Hi Kenny Your back slashes are a mess, Try this:- %((A:GPS WP NEXT ID, string))%!s! Spot the two mitakes ?


Paul EGLD

Share this post


Link to post
Share on other sites

Hi Guys, thanks for the input.Tom, that just go's to show how easy it is to misread the syntax. I know about the backslash being at the front but for some reason I have it in my mind that because it is a finishing statement it should go at the end. My eye and brain has obviously read it and accepted the error. I will be more aware and take extra care in future. Sorry.PVE, I've picked up the one with the backslash error at the end of the text line but I cannot find another one. In my defence, I take medication so I will 'blame the pills'!! for my lack of concentration.If I can get this to work then that will allow me to add code for all of the a/c tanks by picking up the variables from the sim.Please come back and show me the error of my ways. I will keep trying in the meantime. I know that I am very trying Regards...Ken.OK, I also had a backslash at the end of VerticalAdjust="Center"AAARRRGGGHHHHH I'll post back when it works.

Share this post


Link to post
Share on other sites

Hello again folks.I have tried various adjustments to this code. Here is the latest :-%((A:FUEL TOTAL QUANTITY WEIGHT, lbs))%!08,2f!This displays 2f! in white on the window, this is part of the String line. At least I am now getting something but I still cannot figure out what is wrong. The A variable is taken from the SDK but without more experience I am simply assuming that it is the correct one to use.There are eight digits in the C-130 fuel display including the decimal point. The Text X="200" should be plenty pixels to box 8 digits, I think.Any more help will be much appreciated.Regards...Kenny

Share this post


Link to post
Share on other sites

Ted, that was the one that did it. Thanks for coming in to help out. Thanks also to all the folks who chipped in with advice. This has been a learning curve for me. I really need to pay more attention to detail!!I will go on now and code the individual tank levels.Thanks again for all the help. Although no doubt as Arnie said "I'll be back" Regards...Kenny

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...