Alpha Video Training
Results 1 to 4 of 4

Thread: IF Function

  1. #1
    e. ghun
    Guest

    Default IF Function

    Will someone be kind enough to tell me why the following function respond is too few parameters

    IF(Deduct >= 0, Cost*0.75)

    Deduct is a numeric

    Cost is numeric. Many thanks

    e. ghun

  2. #2
    Former Alpha Employee JerryBrightbill's Avatar
    Real Name
    Jerry Brightbill
    Join Date
    Apr 2000
    Posts
    5,171

    Default RE: IF Function

    You only have one argument. An if statement needs a result for both true and false. This is covered in the xbasic manual.

    if(logicalexpression, value if true, value if false)

    IF(Deduct >= 0, Cost*0.75, Cost)

    Jerry

  3. #3
    Member
    Real Name
    Robert Picard
    Join Date
    Apr 2000
    Posts
    326

    Default RE: IF Function

    Just to clarify. If you are creating an expression in forms or reports you do need a second condition.

    Buttt....If you are working in XBasic the "IF" function does not need a second condition although it can be included.

    So if you are used to the way "IF" works in XBasic and start applying it in calculated expressions it can be confusing.

    Robert

  4. #4
    e. ghun
    Guest

    Default RE: IF Function



    Jerry......So thankful I am


    eg

Similar Threads

  1. Function within a function
    By Scott Emerick in forum Alpha Five Version 6
    Replies: 2
    Last Post: 11-21-2004, 08:52 AM
  2. First Function
    By NBGH in forum Alpha Five Version 5
    Replies: 4
    Last Post: 06-16-2004, 04:27 AM
  3. ctl+alt+d function
    By dparkins in forum Alpha Five Version 5
    Replies: 7
    Last Post: 04-01-2003, 08:29 AM
  4. AT() function
    By Ken Whitcomb in forum Alpha Five Version 5
    Replies: 4
    Last Post: 10-24-2002, 03:37 PM
  5. at() function
    By Neil Terry in forum Alpha Five Version 5
    Replies: 3
    Last Post: 10-23-2002, 04:28 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •