Results 1 to 4 of 4

Disable subform

  1. #1
    Behrooz is offline Novice
    Windows XP Access 2013 32bit
    Join Date
    Feb 2019
    Posts
    17

    Disable subform


    Hello, I have a form that includes a text box (unbound) and a sub-form. I want to disable my subform when it's over at 9am. And the user can not enter data. Thank you if anyone can help

    Sent from my SM-J701F using Tapatalk

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    19,881
    You could adapt this:

    http://www.baldyweb.com/ConditionalVisibility.htm

    in the timer event of the form. Your test would look like:

    If Time() > #9:00:00 am# Then

    You'd set the AllowAdditions property of the subform (edits and deletes too if desired). Or just disable the subform control.
    Paul (wino moderator)
    MS Access MVP
    www.BaldyWeb.com

  3. #3
    Behrooz is offline Novice
    Windows XP Access 2013 32bit
    Join Date
    Feb 2019
    Posts
    17
    Quote Originally Posted by pbaldy View Post
    You could adapt this:

    http://www.baldyweb.com/ConditionalVisibility.htm

    in the timer event of the form. Your test would look like:

    If Time() > #9:00:00 am# Then

    You'd set the AllowAdditions property of the subform (edits and deletes too if desired). Or just disable the subform control.
    Many thanks for using the phrase. befor I did not use the # sign, so I did not get the result, but thanks for the time you gave me.

    Sent from my SM-J701F using Tapatalk

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    19,881
    No problem. I take it you got it working?
    Paul (wino moderator)
    MS Access MVP
    www.BaldyWeb.com

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

Similar Threads

  1. Disable tab in subform based on check box
    By russdwright in forum Forms
    Replies: 5
    Last Post: 10-06-2017, 04:45 PM
  2. Disable subform using a module
    By gg80 in forum Programming
    Replies: 4
    Last Post: 05-17-2015, 06:39 PM
  3. disable controls on a subform,
    By jaymin in forum Database Design
    Replies: 2
    Last Post: 06-23-2012, 06:05 AM
  4. Disable new entry in subform
    By mdewell in forum Forms
    Replies: 3
    Last Post: 01-05-2012, 01:38 PM
  5. Replies: 1
    Last Post: 08-06-2010, 06:50 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
  •  
Tech Forums: Microsoft Office Forums