Sign in to follow this  
ark

Novice XML Question

Recommended Posts

The code line 

 

<GaugeString>%((A:Plane heading degrees gyro,degrees))%!03d!</GaugeString>

 

  is used to generate a heading value that is to be displayed on an a/c PFD.

 

I wanted to reduce the value displayed by one degree and thought the following would work, but it doesn't:

 

<GaugeString>%((A:Plane heading degrees gyro,degrees) 1-)%!03d!</GaugeString> .

 

My understanding is the !03d! code section formats the result to 3 digits, and I thought my addition in red would reduce the heading value by 1 before that took place. Clearly I don't understand something basic here. Would appreciate any advice.

 

Would also appreciate recommendations for a good online XML tutorial.

 

Thx,

Al

 

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Bert,

That solved the problem. I would have sworn I had tried that first, but apparently not.

Thanks!

Al

Share this post


Link to post
Share on other sites

I think you could also use -- (ie. decrement) instead of 1 - 

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