469,344 Members | 6,124 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,344 developers. It's quick & easy.

If statement help

Very green at livecycle. I have been trying to figure this out for too long now. Please help.

Employee_5X is a dropdown of employee names
Employee_5X_Start is a dropdown of start times
Employee_5X_End is a dropdown of end times
Employee_5X_Lunch is a dropdown of lunch deduction times
Employee_5X_Total is the calculated total number of hours worked for the day.

If Employee_5X is blank, i want Employee_5X_Total to show 0 or be blank as well. Here is one of the ways i have tried to do it. I have tried java as well, but I am loosing my hair.

Expand|Select|Wrap|Line Numbers
  1. if (Employee_5X.isNull)then
  2. Employee_5X_Total ==0
  3. else
  4. sum (-Employee_5X_Start.rawValue + Employee_5X_End.rawValue + (-Employee_5X_Lunch) + 12)
  5. endif
  6.  
Any help is appreciated
Feb 14 '12 #1
1 1053
The "=="is a comparator not an assignment operator. The "=="is used in a case where your comparing such as (if x == y). Try this:
Expand|Select|Wrap|Line Numbers
  1. Employee_5X_Total =0
  2.  
Feb 17 '12 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

4 posts views Thread by soni29 | last post: by
2 posts views Thread by Little PussyCat | last post: by
11 posts views Thread by Scott C. Reynolds | last post: by
2 posts views Thread by NathanV | last post: by
3 posts views Thread by igendreau | last post: by
3 posts views Thread by samearle | last post: by
3 posts views Thread by schoultzy | last post: by
1 post views Thread by CARIGAR | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.