Using a pushbutton to advance a count.

Any tips?

1 - post your complete program or a short but complete program that illustrates the problem
2 - increment the variable when the button becomes pressed rather than when it is pressed. Look at the StateChangeDetection example in the IDE