Use of the Tip & Trick "Calculate Total of Numeric Property"

Greetings. I followed the Tip/Tick of ‘How to calculate total of numeric property of all pieces in particular location/state’. Very nicely done.

However, I would like to use that numeric property total (Global Property TotalValue, in Map (window) Resourcesetc)in another game piece, in another map (window). ATM as soon as I move that game piece off the Resourcesetc map, the total resets to the default. I’ve tried numerous iterations of calculated property and dynamic Property, all to no avail. I would have thought a Global Property would, indeed, be Globally accessible from anywhere within the module. But, as I’m not a Vassal Developer or Guru, there is most likely something I’m missing.

I would greatly appreciate some advice on how to do this. Thanks.

PS. The module is large. It has many map windows, most accessible via the toolbar or hotkey.

Try moving the Global Property out of the window and into the global properties section of the module itself? That way it will be “truly” global.

YES. Success. Wasn’t working immediately post the change, but on save and reload of module it worked. Many, many thanks. :smiley:

Yeah I think the #1 “Tip and Trick” on getting started in Vassal Development should be ALWAYS EXIT AND RELOAD MODULE! If you touch anything with an underlying prototype, the change usually won’t even take if you “Close Game” and start a new game – it takes going out and restarting the whole module.