Results 1 to 6 of 6
  1. #1
    JSHEL is offline Novice
    Windows XP Access 2007
    Join Date
    Oct 2010
    Posts
    8

    Close on date

    Is there a way to have access look at the current date on open and if it's past a specific date close the database?
    I'm look to put this in Autoexec Macro. or if there is a better way.


    Thank you for your time,
    Jshel

  2. #2
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    store the threashold date in a table and look it up via comparison using DATE() with the macro. issue a:
    Code:
    docmd.quit
    command if the date is past.

    why are you doing it? trial software?

  3. #3
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    You can do it with a macro condition of:

    Date()>#12/01/2010#

    Hopefully you realize that any knowledgeable user will be able to get past it (and probably anything else you might try).
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  4. #4
    JSHEL is offline Novice
    Windows XP Access 2007
    Join Date
    Oct 2010
    Posts
    8
    Thank you for the quick responses. I do realize it's easy to get around just about anything in access <shift>. The person i'm sending this DB to is strictly an end user. LOL (trying to be nice) I just don't want the DB to be used with out payment first. Kind of a sample DB.

  5. #5
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    thy this to disable that key: http://support.microsoft.com/kb/826765

  6. #6
    JSHEL is offline Novice
    Windows XP Access 2007
    Join Date
    Oct 2010
    Posts
    8
    Great information Thank you very much.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. form won't save and close
    By Philislost in forum Access
    Replies: 6
    Last Post: 10-08-2010, 01:47 PM
  2. Add a close button?
    By thestappa in forum Reports
    Replies: 1
    Last Post: 07-15-2010, 10:43 AM
  3. Close All but One Form
    By Bruce in forum Forms
    Replies: 4
    Last Post: 04-06-2010, 09:31 AM
  4. Close DAP Connection
    By gfultz in forum Access
    Replies: 0
    Last Post: 10-16-2009, 10:11 AM
  5. close form
    By taylorosso in forum Forms
    Replies: 5
    Last Post: 08-25-2009, 12:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums