• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 484
  • Last Modified:

How to detect internet inactivity (idle time) using WinINet API?

Hello,
I'm using WinINet API to connect & disconnect to internet, can anybody help me how to detect internet inactivity(idle time/no packet transfer/retrieval using internet).

Thanks in advance
Vini
0
rajg9g
Asked:
rajg9g
1 Solution
 
wcwnetCommented:
One way is to listen for local activity
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dncold/html/ssf1ts.asp
each time your app detects local activity reset your timer, if no activity for a given length of time, then proceed with your disconnect.

I have an app that I do something similar, I monitor all activity on the open IE's, http://www.freevbcode.com/ShowCode.Asp?ID=1606 and set my timer by that.  The top info should work about the same but would watch for any activity not just IE.
0
 
CleanupPingCommented:
Hi rajg9g,
This old question (QID 20567816) needs to be finalized -- accept an answer, split points, or get a refund.  Please see http://www.cityofangels.com/Experts/Closing.htm for information and options.
0
 
GPrentice00Commented:
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

 -->Accept wcwnet's comment as Answer

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER

GPrentice00
Cleanup Volunteer
0

Featured Post

[Webinar] Database Backup and Recovery

Does your company store data on premises, off site, in the cloud, or a combination of these? If you answered “yes”, you need a data backup recovery plan that fits each and every platform. Watch now as as Percona teaches us how to build agile data backup recovery plan.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now