Pic is for attention, also caturday.
Hey fellars, so I'm trying to create this program in java that's supposed to keep track of how much stock there is. Like if you wanted to cook pancakes, you would click a button that said "pancakes" and 1xmilk, 2xtimes egg would be removed from the stock everytime you click the button, the problem is that I have to declare the integers inside the Actionperformed, so everytime I click the button the original values reset, does any kind soul have the answer?
Also, is there perhaps a better board for this?
>>57818259
We're not doing your homework for you, you dumb idiot.
How about don't declare the integers inside the function
>>57818267
haha whoa, it's not homework, I'm doing it for work (not a programming job)
Store the total quantity in a Javadb (or text file or global variable) and manipulate it from there?
>>57818291
>>57819390
This.