Solved

Timer on Access Command Button

Posted on 2013-11-01
3
578 Views
Last Modified: 2013-11-01
Using Access 2007 and using VBA.
Is there any way for a timer to be put on command button that you could not fire it 5 minutes before the hour and 10 minutes after the hour.

Private Sub Command0_Click()

End Sub
0
Comment
Question by:ca1358
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 47

Assisted Solution

by:Dale Fye (Access MVP)
Dale Fye (Access MVP) earned 250 total points
ID: 39617540
you could put code in the timer event of the form and set the forms timerinterval to 30000 (30 seconds).

Private sub Form_Timer

me.cmd_YourbuttonName.Enabled = Minute(Now()) >= 10 AND Minute(Now()) < 55

End Sub
0
 
LVL 120

Accepted Solution

by:
Rey Obrero (Capricorn1) earned 250 total points
ID: 39617565
you also need to set the focus to other control to enable/disable the command button

if the command button has the focus, you will get an error.
0
 

Author Closing Comment

by:ca1358
ID: 39617724
thank you!
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
EXCEL Name Matching 13 37
Tricky Shapes formula 3 13
access query filter for lower case lett 7 17
Hash on Excel 13 35
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
How to get Spreadsheet Compare 2016 working with the 64 bit version of Office 2016
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

735 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question