473,486 Members | 1,953 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Detect Idle Time

I have a routine which checks idle time and opens a pop up screen to advise
users before shutting them down. The pop up has an option for the user to
keep the application open, in which case the timer is reset for another
period.
The problem occurs if the user is working on another application at the time
the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they can
see the message?
Or is there another (more obvious?) solution to my problem?

--
Bob Darlington
Brisbane
Nov 15 '07 #1
21 5467
Could you open the MsgBox as system modal, Bob?

This works in Access 2007:

Private Sub Form_Timer()
If MsgBox("Time's up. Okay?", vbSystemModal + vbYesNo, "Quitting") =
vbYes Then
'whatever
End If
End Sub
--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
>I have a routine which checks idle time and opens a pop up screen to advise
users before shutting them down. The pop up has an option for the user to
keep the application open, in which case the timer is reset for another
period.
The problem occurs if the user is working on another application at the
time the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they can
see the message?
Or is there another (more obvious?) solution to my problem?

--
Bob Darlington
Brisbane
Nov 15 '07 #2
Bob Darlington wrote:
I have a routine which checks idle time and opens a pop up screen to advise
users before shutting them down. The pop up has an option for the user to
keep the application open, in which case the timer is reset for another
period.
The problem occurs if the user is working on another application at the time
the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they can
see the message?
Or is there another (more obvious?) solution to my problem?
Probably want Access taskbar icon to flash? Check out this API:

Private Declare Function FlashWindowEx Lib "user32" (pflashwininfo As
FLASHWINFO) As Long

I'm sure someone has done some VB/VBA code with this....

--
'--------------------------
' John Mishefske
' UtterAccess Editor
' 2007 Microsoft MVP
'--------------------------
Nov 15 '07 #3
Thanks Allen,
That works fine as long as the user is at his desk. But if not, it stops the
shutdown routine from quitting.
Is there any way to close an unanswered message box?

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
Could you open the MsgBox as system modal, Bob?

This works in Access 2007:

Private Sub Form_Timer()
If MsgBox("Time's up. Okay?", vbSystemModal + vbYesNo, "Quitting") =
vbYes Then
'whatever
End If
End Sub
--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
>>I have a routine which checks idle time and opens a pop up screen to
advise users before shutting them down. The pop up has an option for the
user to keep the application open, in which case the timer is reset for
another period.
The problem occurs if the user is working on another application at the
time the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they
can see the message?
Or is there another (more obvious?) solution to my problem?

--
Bob Darlington
Brisbane

Nov 15 '07 #4
Perhaps you could create your own little dialog form, and open in in dialog
mode in the Timer event of your original form:
DoCmd.OpenForm "Form1", WindowMode:=acDialog

This new form could then have a default response in its own Timer event.

There's a few more details to sort out (to do with suppressing your dialog
being opened again immediately after), but that's the basic idea.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
Thanks Allen,
That works fine as long as the user is at his desk. But if not, it stops
the shutdown routine from quitting.
Is there any way to close an unanswered message box?

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
>Could you open the MsgBox as system modal, Bob?

This works in Access 2007:

Private Sub Form_Timer()
If MsgBox("Time's up. Okay?", vbSystemModal + vbYesNo, "Quitting") =
vbYes Then
'whatever
End If
End Sub
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com. au...
>>>I have a routine which checks idle time and opens a pop up screen to
advise users before shutting them down. The pop up has an option for the
user to keep the application open, in which case the timer is reset for
another period.
The problem occurs if the user is working on another application at the
time the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they
can see the message?
Or is there another (more obvious?) solution to my problem?

--
Bob Darlington
Brisbane
Nov 15 '07 #5
Bob Darlington wrote:
>I have a routine which checks idle time and opens a pop up screen to
advise users before shutting them down. The pop up has an option for
the user to keep the application open, in which case the timer is
reset for another period.
The problem occurs if the user is working on another application at
the time the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they
can see the message?
Or is there another (more obvious?) solution to my problem?
John Mishefske wrote:
Probably want Access taskbar icon to flash? Check out this API:

Private Declare Function FlashWindowEx Lib "user32" (pflashwininfo As
FLASHWINFO) As Long

I'm sure someone has done some VB/VBA code with this....
Some additional info including input from Albert Kallal:

http://discuss.fogcreek.com/joelonso...6&ixReplies=21

--
'--------------------------
' John Mishefske
' UtterAccess Editor
' 2007 Microsoft MVP
'--------------------------
Nov 15 '07 #6
Allen.
I am using a pop up form (as opposed to a message box) but I wasn't opening
it with acDialog.
So I changed it to a dialog, but it won't pop up when another application is
in use. It still skulks unseen under everything else.
I'm considering using a sound warning with a wave file to generate an alert
that the dialog is open.

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
Perhaps you could create your own little dialog form, and open in in
dialog mode in the Timer event of your original form:
DoCmd.OpenForm "Form1", WindowMode:=acDialog

This new form could then have a default response in its own Timer event.

There's a few more details to sort out (to do with suppressing your dialog
being opened again immediately after), but that's the basic idea.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
>Thanks Allen,
That works fine as long as the user is at his desk. But if not, it stops
the shutdown routine from quitting.
Is there any way to close an unanswered message box?

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
>>Could you open the MsgBox as system modal, Bob?

This works in Access 2007:

Private Sub Form_Timer()
If MsgBox("Time's up. Okay?", vbSystemModal + vbYesNo, "Quitting") =
vbYes Then
'whatever
End If
End Sub
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com .au...
I have a routine which checks idle time and opens a pop up screen to
advise users before shutting them down. The pop up has an option for the
user to keep the application open, in which case the timer is reset for
another period.
The problem occurs if the user is working on another application at the
time the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they
can see the message?
Or is there another (more obvious?) solution to my problem?

--
Bob Darlington
Brisbane

Nov 15 '07 #7
Hmm: it worked in myt current version (Access 2007), Bob.

I did not set the form's Popup or Modal properties: just opened it acDialog.
With Access 2007 minimized to the task bar, the window poped up outside the
Access window.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
Allen.
I am using a pop up form (as opposed to a message box) but I wasn't
opening it with acDialog.
So I changed it to a dialog, but it won't pop up when another application
is in use. It still skulks unseen under everything else.
I'm considering using a sound warning with a wave file to generate an
alert that the dialog is open.

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
>Perhaps you could create your own little dialog form, and open in in
dialog mode in the Timer event of your original form:
DoCmd.OpenForm "Form1", WindowMode:=acDialog

This new form could then have a default response in its own Timer event.

There's a few more details to sort out (to do with suppressing your
dialog being opened again immediately after), but that's the basic idea.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com. au...
>>Thanks Allen,
That works fine as long as the user is at his desk. But if not, it stops
the shutdown routine from quitting.
Is there any way to close an unanswered message box?

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
Could you open the MsgBox as system modal, Bob?

This works in Access 2007:

Private Sub Form_Timer()
If MsgBox("Time's up. Okay?", vbSystemModal + vbYesNo, "Quitting") =
vbYes Then
'whatever
End If
End Sub
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.co m.au...
>I have a routine which checks idle time and opens a pop up screen to
>advise users before shutting them down. The pop up has an option for
>the user to keep the application open, in which case the timer is reset
>for another period.
The problem occurs if the user is working on another application at
the time the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they
can see the message?
Or is there another (more obvious?) solution to my problem?
>
--
Bob Darlington
Brisbane
Nov 15 '07 #8
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
Allen.
I am using a pop up form (as opposed to a message box) but I wasn't
opening it with acDialog.
So I changed it to a dialog, but it won't pop up when another application
is in use. It still skulks unseen under everything else.
I'm considering using a sound warning with a wave file to generate an
alert that the dialog is open.
That's going to make you very unpopular with your users. Can I as why you
want this functionality? Is it really necessary? There are ways to force
users out of an Access application if it's needed for maintenance purposes.
Would that suit your purposes?

Keith.
www.keithwilby.com

Nov 15 '07 #9
Keith,
I have users (using TS) who often leave their workstations without closing
the program, so that maintenance cannot be done. Some even forget that they
haven't saved an edit before leaving.
So they need to be kicked out.
But this thread is to do with making me less 'unpopular', by notifying them
in advance (if they're still at their desks) and giving them the opportunity
to continue.

--
Bob Darlington
Brisbane
"Keith Wilby" <he**@there.comwrote in message
news:47**********@glkas0286.greenlnk.net...
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
>Allen.
I am using a pop up form (as opposed to a message box) but I wasn't
opening it with acDialog.
So I changed it to a dialog, but it won't pop up when another application
is in use. It still skulks unseen under everything else.
I'm considering using a sound warning with a wave file to generate an
alert that the dialog is open.

That's going to make you very unpopular with your users. Can I as why you
want this functionality? Is it really necessary? There are ways to force
users out of an Access application if it's needed for maintenance
purposes. Would that suit your purposes?

Keith.
www.keithwilby.com

Nov 15 '07 #10
Allen.
With Access minimised to the task bar, and only the desktop visible (ie
other apps minimised as well), it works fine. But, if the user is using
another app (eg Outlook) then it doesn't appear. This is using Access 2002
in Windows XP Pro.
I have tried setting it to a pop up modal and opening with acDialog.

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
Hmm: it worked in myt current version (Access 2007), Bob.

I did not set the form's Popup or Modal properties: just opened it
acDialog. With Access 2007 minimized to the task bar, the window poped up
outside the Access window.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
>Allen.
I am using a pop up form (as opposed to a message box) but I wasn't
opening it with acDialog.
So I changed it to a dialog, but it won't pop up when another application
is in use. It still skulks unseen under everything else.
I'm considering using a sound warning with a wave file to generate an
alert that the dialog is open.

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
>>Perhaps you could create your own little dialog form, and open in in
dialog mode in the Timer event of your original form:
DoCmd.OpenForm "Form1", WindowMode:=acDialog

This new form could then have a default response in its own Timer event.

There's a few more details to sort out (to do with suppressing your
dialog being opened again immediately after), but that's the basic idea.

"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com .au...
Thanks Allen,
That works fine as long as the user is at his desk. But if not, it
stops the shutdown routine from quitting.
Is there any way to close an unanswered message box?

--
Bob Darlington
Brisbane
"Allen Browne" <Al*********@SeeSig.Invalidwrote in message
news:47***********************@per-qv1-newsreader-01.iinet.net.au...
Could you open the MsgBox as system modal, Bob?
>
This works in Access 2007:
>
Private Sub Form_Timer()
If MsgBox("Time's up. Okay?", vbSystemModal + vbYesNo, "Quitting")
= vbYes Then
'whatever
End If
End Sub
>
>
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.c om.au...
>>I have a routine which checks idle time and opens a pop up screen to
>>advise users before shutting them down. The pop up has an option for
>>the user to keep the application open, in which case the timer is
>>reset for another period.
>The problem occurs if the user is working on another application at
>the time the pop up is activated, in which case it cannot be seen.
>Is there any way to shift the focus back to my access app so that
>they can see the message?
>Or is there another (more obvious?) solution to my problem?
>>
>--
>Bob Darlington
>Brisbane

Nov 15 '07 #11
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47**********************@news.optusnet.com.au ...
Keith,
I have users (using TS) who often leave their workstations without closing
the program, so that maintenance cannot be done. Some even forget that
they haven't saved an edit before leaving.
So they need to be kicked out.
So how about considering the functionality I suggested, the ability to kick
off all users at the push of a button and to keep them out until you've
finished what you need them out for?
But this thread is to do with making me less 'unpopular', by notifying
them in advance (if they're still at their desks) and giving them the
opportunity to continue.
It was the prospect of a sound being played that I thought would make that
aspect unpopular. I don't understand why you're giving users the
opportunity to continue if you need them out. I have some code that will
achieve what I'm suggesting if you want it. You can target individual
users, individual machines, or all users and machines.

Regards,
Keith.

Nov 15 '07 #12
On Thu, 15 Nov 2007 00:24:02 -0600, John Mishefske
<jm**********@SPAMyahoo.comwrote:
>Bob Darlington wrote:
>I have a routine which checks idle time and opens a pop up screen to advise
users before shutting them down. The pop up has an option for the user to
keep the application open, in which case the timer is reset for another
period.
The problem occurs if the user is working on another application at the time
the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they can
see the message?
Or is there another (more obvious?) solution to my problem?

Probably want Access taskbar icon to flash? Check out this API:

Private Declare Function FlashWindowEx Lib "user32" (pflashwininfo As
FLASHWINFO) As Long

I'm sure someone has done some VB/VBA code with this....

http://support.microsoft.com/kb/254339
Please Post Any Replies To This Message Back To the Newsgroup.
There are "Lurkers" around who can benefit by our exchange!
Nov 16 '07 #13
On Thu, 15 Nov 2007 15:49:28 +1000, "Bob Darlington"
<bo*@dpcmanAX.com.auwrote:
>I have a routine which checks idle time and opens a pop up screen to advise
users before shutting them down. The pop up has an option for the user to
keep the application open, in which case the timer is reset for another
period.
The problem occurs if the user is working on another application at the time
the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they can
see the message?
Or is there another (more obvious?) solution to my problem?
The (oft posted) "Kick 'em Out" routine is the most common way to do
this.

Personally, I would just call the messagebox API directly with the
MB_SYSTEMMODAL option to have the application switch to Access. This
tends to *really* annoy users however, so I doubt I'd use it anymore.
(Common in applications written by programmers who feel *their*
application is the most important application running....)

Calling the messagebox API with MB_ICONEXCLAMATION or the
MB_ICONQUESTION option (Setting?) will cause the user's application
alert sound to occur, however in TS environments, it's fairly common
for sounds not to come across, so it's use is dubious.

Just use the SetTimer API call to cause the MessageBox API to go away
automatically. It will return the default setting of the MessageBox,
so set that accordingly to what return you want to happen if the user
doesn't press anything.

In this case however, all of the above is overkill. The "kick 'em
out" routine would be the preferred method. Arvin Meyer has a copy of
it at his site: <http://www.datastrat.com/Code/KickEmOff.txt>


Please Post Any Replies To This Message Back To the Newsgroup.
There are "Lurkers" around who can benefit by our exchange!
Nov 16 '07 #14
Chuck Grimsby wrote:
On Thu, 15 Nov 2007 00:24:02 -0600, John Mishefske
<jm**********@SPAMyahoo.comwrote:
>Bob Darlington wrote:
>>The problem occurs if the user is working on another application at the time
the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they can
see the message?
Or is there another (more obvious?) solution to my problem?
Probably want Access taskbar icon to flash? Check out this API:

Private Declare Function FlashWindowEx Lib "user32" (pflashwininfo As
FLASHWINFO) As Long

I'm sure someone has done some VB/VBA code with this....


http://support.microsoft.com/kb/254339
Thanks Chuck.

For those interested in trying this code you should note that it was
meant for VB5/VB6 but will run unaltered in Access causing the form
that this code runs in to flash.

You can change the hWnd variable assignment to use the Application
Handle instead of the Handle to the form if you want Access itself to
flash (taskbar icon flashes):

' Fill the structure:
With FWInfo
.cbSize = Len(FWInfo) ' 20
'.hWnd = Me.hWnd ' flash the form
.hWnd = Application.hWndAccessApp ' flash the app
.dwFlags = FLASHW_ALL
.uCount = 5 ' number of times to flash
.dwTimeout = 0 ' how frequently (0 = default)
End With
--
'--------------------------
' John Mishefske
' UtterAccess Editor
' 2007 Microsoft MVP
'--------------------------
Nov 16 '07 #15
Keith,
Thanks for the reply & sorry about the delay responding.
There are 2 situations. One, where I need to kick 'em out to do maintenance,
in which case they don't get the option. This one is working fine, and has
been for a number of years.
The second is where a user has been inactive and forgotten to close the app.
In this case, there is a risk that they have left unsaved edits which is
obviously not desirable. It's also a question of preserving network
resources. In this second case, I want to be able to give some sort of
warning. If they've left their desk, then they wont respond, and will be
kicked out after a number of seconds. But if they are still at their desk,
and in another application, I want to give them the chance to restart the
clock.
Hope that makes things clearer.
Does your code address this problem?

--
Bob Darlington
Brisbane
"Keith Wilby" <he**@there.comwrote in message
news:47**********@glkas0286.greenlnk.net...
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47**********************@news.optusnet.com.au ...
>Keith,
I have users (using TS) who often leave their workstations without
closing the program, so that maintenance cannot be done. Some even forget
that they haven't saved an edit before leaving.
So they need to be kicked out.

So how about considering the functionality I suggested, the ability to
kick off all users at the push of a button and to keep them out until
you've finished what you need them out for?
>But this thread is to do with making me less 'unpopular', by notifying
them in advance (if they're still at their desks) and giving them the
opportunity to continue.

It was the prospect of a sound being played that I thought would make that
aspect unpopular. I don't understand why you're giving users the
opportunity to continue if you need them out. I have some code that will
achieve what I'm suggesting if you want it. You can target individual
users, individual machines, or all users and machines.

Regards,
Keith.

Nov 20 '07 #16
On Nov 15, 9:19 pm, Chuck Grimsby <c.grim...@worldnet.att.net.invalid>
wrote:
On Thu, 15 Nov 2007 15:49:28 +1000, "Bob Darlington"
Personally, I would just call the messagebox API directly with the
MB_SYSTEMMODAL option to have the application switch to Access. This
tends to *really* annoy users however, so I doubt I'd use it anymore.
(Common in applications written by programmers who feel *their*
application is the most important application running....)
I would never knowingly buy or use an application that disrespects me
sufficiently to disturb my work with a message about idle time, or
shuts itself off.
Throughout an application development career of about twenty-five
years I have always emphasized confidence in and respect for the user
and I have never regretted doing so.

Nov 20 '07 #17
lyle <ly************@gmail.comwrote:
>I would never knowingly buy or use an application that disrespects me
sufficiently to disturb my work with a message about idle time, or
shuts itself off.
Throughout an application development career of about twenty-five
years I have always emphasized confidence in and respect for the user
and I have never regretted doing so.
However people are forgetful. Yes, we know they should cleanly exit but it simply
doesn't happen sometimes.

Tony
--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
Tony's Microsoft Access Blog - http://msmvps.com/blogs/access/
Nov 20 '07 #18
Lyle,
I suppose it depends on whether:
a. You need to maintain your client data file on line
b. Your clients are all 'perfect' users.
Unfortunately, all my users don't fall into that category, so I'm seeking
some options.
I've found that provided I work through this type of problem with the
clients, I don't get any agro. As long as they know what is going on.
I'm talking about a small client base do it's possible to do it this way.

--
Bob Darlington
Brisbane
"lyle" <ly************@gmail.comwrote in message
news:d7**********************************@w28g2000 hsf.googlegroups.com...
On Nov 15, 9:19 pm, Chuck Grimsby <c.grim...@worldnet.att.net.invalid>
wrote:
>On Thu, 15 Nov 2007 15:49:28 +1000, "Bob Darlington"
>Personally, I would just call the messagebox API directly with the
MB_SYSTEMMODAL option to have the application switch to Access. This
tends to *really* annoy users however, so I doubt I'd use it anymore.
(Common in applications written by programmers who feel *their*
application is the most important application running....)

I would never knowingly buy or use an application that disrespects me
sufficiently to disturb my work with a message about idle time, or
shuts itself off.
Throughout an application development career of about twenty-five
years I have always emphasized confidence in and respect for the user
and I have never regretted doing so.

Nov 20 '07 #19
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
Keith,
Thanks for the reply & sorry about the delay responding.
There are 2 situations. One, where I need to kick 'em out to do
maintenance, in which case they don't get the option. This one is working
fine, and has been for a number of years.
The second is where a user has been inactive and forgotten to close the
app. In this case, there is a risk that they have left unsaved edits which
is obviously not desirable. It's also a question of preserving network
resources. In this second case, I want to be able to give some sort of
warning. If they've left their desk, then they wont respond, and will be
kicked out after a number of seconds. But if they are still at their desk,
and in another application, I want to give them the chance to restart the
clock.
Hope that makes things clearer.
Does your code address this problem?
Hi Bob,

No it doesn't but I did used to have some code that does what you're after.
Unfortunately I discarded it years ago because I got too many complaints
from the end users. I will have a dig around to see if I can find it but
I'm not hopeful.

Regards,
Keith.

Nov 20 '07 #20
Thanks Chuck.
A Google search for 'Flash Taskbar' got a post from 'Salad' (27 Oct 2004 in
this ng) which does exactly what I wanted.
Thanks again for your help.

--
Bob Darlington
Brisbane
"Chuck Grimsby" <c.*******@worldnet.att.net.invalidwrote in message
news:ef********************************@4ax.com...
On Thu, 15 Nov 2007 00:24:02 -0600, John Mishefske
<jm**********@SPAMyahoo.comwrote:
>>Bob Darlington wrote:
>>I have a routine which checks idle time and opens a pop up screen to
advise
users before shutting them down. The pop up has an option for the user
to
keep the application open, in which case the timer is reset for another
period.
The problem occurs if the user is working on another application at the
time
the pop up is activated, in which case it cannot be seen.
Is there any way to shift the focus back to my access app so that they
can
see the message?
Or is there another (more obvious?) solution to my problem?

Probably want Access taskbar icon to flash? Check out this API:

Private Declare Function FlashWindowEx Lib "user32" (pflashwininfo As
FLASHWINFO) As Long

I'm sure someone has done some VB/VBA code with this....


http://support.microsoft.com/kb/254339
Please Post Any Replies To This Message Back To the Newsgroup.
There are "Lurkers" around who can benefit by our exchange!

Nov 20 '07 #21
Thanks Keith.
Don't worry, I found exactly what I wanted using 'Flash Taskbar' posted to
this group in 2004.

--
Bob Darlington
Brisbane
"Keith Wilby" <he**@there.comwrote in message
news:47**********@glkas0286.greenlnk.net...
"Bob Darlington" <bo*@dpcmanAX.com.auwrote in message
news:47***********************@news.optusnet.com.a u...
>Keith,
Thanks for the reply & sorry about the delay responding.
There are 2 situations. One, where I need to kick 'em out to do
maintenance, in which case they don't get the option. This one is working
fine, and has been for a number of years.
The second is where a user has been inactive and forgotten to close the
app. In this case, there is a risk that they have left unsaved edits
which is obviously not desirable. It's also a question of preserving
network resources. In this second case, I want to be able to give some
sort of warning. If they've left their desk, then they wont respond, and
will be kicked out after a number of seconds. But if they are still at
their desk, and in another application, I want to give them the chance to
restart the clock.
Hope that makes things clearer.
Does your code address this problem?

Hi Bob,

No it doesn't but I did used to have some code that does what you're
after. Unfortunately I discarded it years ago because I got too many
complaints from the end users. I will have a dig around to see if I can
find it but I'm not hopeful.

Regards,
Keith.

Nov 20 '07 #22

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
3968
by: Stephane Belzile | last post by:
Is there a way I can detect in vb.Net the power has switched to a UPS unit in case of power failure? Thanks
2
1956
by: Keith Wilby | last post by:
The link below: http://support.microsoft.com/default.aspx?scid=kb;en-us;128814 to the Microsoft KB "Detect Idle Time" article shows how to detect "idle" time. However, if a user is active but...
1
5813
by: jdph40 | last post by:
I am using Access 2002. I downloaded the forms sample database FrmSmp97.mdb from Microsoft and used the following code in the timer event of a hidden form in order to close a database if no...
19
46551
by: Frank Rizzo | last post by:
I want to log the user out when there has been a period of inactivity in the application. The key here is inactivity of the application, not the system. I know that you can retrieve the...
3
1389
by: Law | last post by:
To all the VB master, i'm new baby in VB. I would like to get ur's advice on how to stop the application when user is not in use within 5 or 10mins? Hope to hear VB master soon. Tks, Law
0
1511
by: MIke Kansky | last post by:
I need to detect when user's computer goes to idle mode. I also need to detect when user's computer comes back from the idle mode. I have an application running in Sys Tray that should let the...
5
3686
by: LG | last post by:
Hi, I have recently used the Microsoft that will detect idle time coding on my Access database and it works fine as long as you do not add any data or move from one form to another. As soon as...
3
6967
by: Peri | last post by:
Dear All, Can you please help me out in detecting the application idle time. I would like to lock the application if it is idle for more that 10 minutes. FYI - I have already tried...
2
7213
by: RP | last post by:
I want to detect user activity (mouse move, key click). For certain critical areas (Form in my app.), I want to check whether there is any user activity for a certain interval. If not, then I want...
0
7094
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6964
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7123
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7305
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5427
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4863
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4559
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3070
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1378
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.