Results 1 to 11 of 11
  1. #1
    New Lounger
    Join Date
    Mar 2006
    Location
    Whittier, California, USA
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Date() Not Working (2003)

    My work just bought me a new computer. Since both computers have Access 2003 I didn't think that there would be compatibility problems, but any query with Date() in the criteria box won't open in the new computer. I get an error message "Function is not available in expressions in query expression '(((tblSchd.RotDate) = Date())))'. " I checked the references, and they're the same in both programs. What is the problem here?

    Thanks,

    Kevin

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date() Not Working (2003)

    Welcome to Woody's Lounge!

    Even though you have checked the references, it still seems most likely that the problem is related to references. Which ones are ticked?

  3. #3
    New Lounger
    Join Date
    Mar 2006
    Location
    Whittier, California, USA
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date() Not Working (2003)

    Visual Basic for Applications
    Microsoft Access 11.0 Object Library
    OLE Atomation
    Microsoft ActiveX Data Objects 2.1 Library
    Microsoft DAO 3.6 Object Library
    Microsoft Outlook 11.0 Object Library
    Microsoft Scripting Runtime
    SafeOutlook Library

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date() Not Working (2003)

    All except the last are standard Microsoft Libraries. SafeOutlook is the object library for Outlook Redemption. Are you sure that Redemption has been installed on the problem PC?

  5. #5
    New Lounger
    Join Date
    Mar 2006
    Location
    Whittier, California, USA
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date() Not Working (2003)

    Yes, and I just sent a SafeMail message to myself using the new computer, so I don't think that this is the issue. Any other ideas? Something to do with Access security features that might have changed in the last year?

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date() Not Working (2003)

    Some VBA functions don't work in queries for security reasons, but Date() is not one of them (see How to configure Jet 4.0 to prevent unsafe functions from running in Access 2003)

    Try removing references one by one (in a copy of the database) to see if the error goes away (you cannot remove the first two)

  7. #7
    New Lounger
    Join Date
    Mar 2006
    Location
    Whittier, California, USA
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date() Not Working (2003)

    I was wrong, it was the Redemption Object that was causing the problem. After removing it from my References my queries work fine again.

    I guess I'll have to visit their web site to try to figure out why this is happening? I never had any problems on my old computer.

    Thanks Han [img]/forums/images/smilies/smile.gif[/img]

  8. #8
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date() Not Working (2003)

    You could try reinstalling Redemption to see if you can then add the reference again.

  9. #9
    New Lounger
    Join Date
    Mar 2006
    Location
    Whittier, California, USA
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date() Not Working (2003)

    Thanks, I'll try that. Also, my new computer is set with very restrictive controls for users who are not administrators. When I check the properties of the Redemption.dll file it says that I have Read & Execute and Read permission. I'm wondering if I need additional permissions for the program to work properly (in my old computer I have Full Control)?

    Kevin

  10. #10
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Date() Not Working (2003)

    I don't think you need more than read and execute permission on a DLL.

  11. #11
    New Lounger
    Join Date
    Mar 2006
    Location
    Whittier, California, USA
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Date() Not Working (2003)

    Hi Hans,

    I finally thought of doing what should have been my first step - rebooting my computer [img]/forums/images/smilies/smile.gif[/img] Now the Redemption object & Access seem to be cooperating well together. I'll keep my fingers crossed!

    Thanks again for your help,

    Kevin

Posting Permissions

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