Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Forums   Help   Contact   Merch   Join   Order   Logon  
 
Back to Access Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Custom Popup w Timer
Austin Ritner 
    
6 years ago
I'm running a dispatch program, and would like to have a pop-up on the screen every 5 or so minutes to tell the dispatcher to check on the unit, without being able to click away from it.

Pop-up/Modal would both be "Yes."

Seems like I would use the Timer Interval event and run some VBA from that.

Since the unit assigned to a call is going to be different sometimes, I need that message box text to say something like "Unit Check (xxx)" whoever is assigned to the call.

I'm sure I'm making this way harder than it should be :)
Richard Rost  @Reply  
          
6 years ago
Which part do you need help with? You pretty much answered your own question. Use the Timer Interval property set to 300000 (1000 ms x 60 sec x 5 min). Then in your Timer Event you could just use a MsgBox command, which by its very nature is modal/popup. Do you need something more than that? If so, let me know what your wish list is. This would make a nifty TechHelp video. Yeah, I said "nifty."
Richard Rost  @Reply  
          
6 years ago
I could do a custom popup form with a message that's big and bold that reads a value from a table to determine who's name to put in the popup, like "Unit Check (Joe)" and even play a custom sound (WAV file) like a siren or something. You could even log what time it popped up and what time it was closed (OK). Sky's the limit.
Austin Ritner OP  @Reply  
    
6 years ago
oh goodness haha. well, I actually got the custom message on the msgbox. just did a little concatenation and used CStr to convert the value to a string.

But now I need to click a checkbox that says "no more unit checks" and stop that timer. I've tried the OnCurrent and AfterUpdate but it still seems to pop up even if that box is checked.

now that i'm thinking about it, might have to do more research on message boxes
Richard Rost  @Reply  
          
6 years ago
There are a few ways you can stop the timer. I suggest when you check the box, set the TimerInterval property to 0. That stops the time completely. Or, in your Timer Event, just say

If MyBox = TRUE then exit sub

That will exit the timer event without letting it run if the box is checked, but the timer will still keep counting down in the background.
Austin Ritner OP  @Reply  
    
6 years ago
got it!

i currently have
Private Sub UnitCheck_Click()
     If UnitCheck = True Then
          Me.TimerInterval = 0
     Else
          Me.TimerInterval = 300000 (just in case I need to have unit checks again)
     End If
     Me.Refresh

I had the issue of after I checked the box that it would still be running the timer event, but it would stop after the NEXT time I clicked "OK", but with that Refresh in there, it stops it dead in its tracks.

Will let you know if any other problems arise!

Thanks
Richard Rost  @Reply  
          
6 years ago
Awesome. Glad to help. I've got someone else who asked a question about form timers for TechHelp, but he's only a Silver member, so he's low on the list. LOL

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 5/2/2026 3:44:13 AM. PLT: 1s