switch statement - Java application if/case recommendation -


I am writing an application for a Java course, I am completely starting up I have learned from This application is showing some behavior and I am not sure what is happening due to it. The application is GUI based and calculates on user input. For the verb listener category, if I have a set of statements: "If this button does this then this button does this"

All in a row like this. It seems that instead of pressing the application button, instead of running the matching user, all if statements are running.

Would it be better to use case / switch structure for this type of thing?

If necessary, I can post my code, I am new to this site and I am not sure whether this is acceptable or not.

Until I see my code, I have to guess, but seeing my accepted newness If you like this statement

  if (condition); {...}  

This type of

  if (condition) {...}  

Comments

Popular posts from this blog

c# - ListView onScroll event -

PHP - get image from byte array -

Linux Terminal Problem with Non-Canonical Terminal I/O app -