Tricky Pop Up Alert (1 Viewer)

Emohawk

What a wicked mullet...
Local time
Today, 11:48
Joined
Mar 14, 2002
Messages
79
I've written a smallish chat room program in access 97 for my team at work to "boost productivty". What I need to know is, is there a way to create a pop up message box that appears when the access screen is minimised, ala Microsoft Messenger?
 

boblarson

Smeghead
Local time
Today, 03:48
Joined
Jan 12, 2001
Messages
32,059
Someone else may have a better suggestion, but first of all, Access won't just tell you when something new has happened. You'll need to ask it if something new has happened.

Having said that, I would suggest maybe using a hidden form with a timer event to refresh the database at a specified interval and then if the records in a table you are using for the messages has changed then have code to trigger a pop up message box.

If you have your app minimized you can still open a dialog in Pop Up mode and it will come on screen. However, it will not automatically jump to the front. So, you'll need to program for that.

Hope that helps.

Smoke me a kipper, I'll be back for breakfast

BL
 

Emohawk

What a wicked mullet...
Local time
Today, 11:48
Joined
Mar 14, 2002
Messages
79
The DB itself runs fine, it's already in use. Just was wanting to get some add functionality. I've found some code that responds to the window being minimized however as the application is minimized this event isn't triggered as the app itself still thinks the window is still open. Any ideas?

I'll give you a Double Rimmer if you can help me on this one.

Cheers
 

Emohawk

What a wicked mullet...
Local time
Today, 11:48
Joined
Mar 14, 2002
Messages
79
Argh!!! When the access window is minimized the timer function halts. I getting the feeling that this wont work in access any help/work arounds? The code I found in the microsoft documentation apparently works but if everything in Access halts when will the call to check if the application is minimized happen? Catch 22!!
 

David R

I know a few things...
Local time
Today, 05:48
Joined
Oct 23, 2001
Messages
2,633
Because the code calls apiGetActiveWindow(), you're not going to be able to get it to remember Access when you've got it minimized, as far as I can tell.

I haven't tested it, but can't you use the OnTimer/TimerInterval functions within Access in conjunction with this? I know my 'clock' timer runs in the background, though I don't know about minimized.

HTH,
David R
 

SteveA

Registered User.
Local time
Today, 20:48
Joined
Oct 8, 2001
Messages
126
The timer event in Access still runs when Access is minimised. You could use the timer to trigger your message box, however this will not move the focus from the application you are working in back to Access. I'm not sure how you would do this, but it is probably an API call.

Cheers,
SteveA
 

Users who are viewing this thread

Top Bottom