1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Solved: Access 2010 Error Handling with DateAdd

Discussion in 'Business Applications' started by Dobber9, Dec 20, 2011.

Thread Status:
Not open for further replies.
  1. Dobber9

    Dobber9 Thread Starter

    Joined:
    Dec 20, 2011
    Messages:
    11
    I'm working with query that is used to keep track of what items need to be calibrated and when. The fields being used for my particular situation are Last Calibration Date, Calibration Interval, and Calibration Due date. What I want to happen is for the Calibration Due Date field to display the Calibration Interval (in months) added to the Last Calibration Date. Using the DateAdd function, I was able to do that fairly easily. My problem is, there are some entries that do not have a Last Calibration Date entered into their record. For those records, I don't want the "#Error" to show up in the query, I just want it to remain blank. I'm using Access 2010 on Windows XP.

    Thanks,
    Dobber9
     
  2. OBP

    OBP

    Joined:
    Mar 8, 2005
    Messages:
    19,895
    Dobber9 , welcome to the Forum.
    You can enclose your current calculation in an IIF() statement, something like
    iif(isnull([Last Calibration Date]), "", your calculation goes here)
     
  3. Dobber9

    Dobber9 Thread Starter

    Joined:
    Dec 20, 2011
    Messages:
    11
    Well that's a lot more simple than I made it out to be!

    Thanks very much!
    Dobber9
     
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/1032120

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice