This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes JSP and the fly likes C:if misunderstanding Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » JSP
Bookmark "C:if misunderstanding" Watch "C:if misunderstanding" New topic

C:if misunderstanding

Charessa Reilly
Ranch Hand

Joined: May 26, 2011
Posts: 39
I think I'm operating under some sort of misunderstanding of "if" or maybe JSP and even Java in general. I have this code:

When it executes I get a popup alert that says "simone mitchell" (the value previously put into irecord.manager) then a popup that says "up yours" (you can tell I'm getting frustrated at this)

Shouldn't I get a popup in between the two? How can both those "if" statments fail?
Charessa Reilly
Ranch Hand

Joined: May 26, 2011
Posts: 39

it could be I'm stupid. Just noticed I'm missing some $ there.
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63211

Also use the empty operator rather than testing for null.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Have you checked out Aspose?
subject: C:if misunderstanding
It's not a secret anymore!