It helps to print out the values of the Strings that are being compared so you can see what the code is doing.
Add some printlns just before the if test with the equals() to show their values....
Type: Posts; User: Norm
It helps to print out the values of the Strings that are being compared so you can see what the code is doing.
Add some printlns just before the if test with the equals() to show their values....
See post #6
Does it work now?
Use the equals() method when comparing the contents of two Strings, not the == operator