Dave Tolls wrote:Where is the variable total declared?
It looks like it's not local to the method, so the value is retained between calls to stateChanged.
Carey Brown wrote:Where do you initialize total to zero?
Can you explain more on this ?
Rob Camick wrote:Don't keep a "total" variable.
simply iterate through all the rows in the table to recalculate the total.
John Joe wrote:How should I get rid of the first row of JTable in order to get the total value ?
I didn't like the taste of tongue and it didn't like the taste of me. I will now try this tiny ad:
ScroogeXHTML - small and flexible RTF to HTML converter libraryhttps://coderanch.com/t/710903/ScroogeXHTML-RTF-HTML-XHTML-converter