Solved

icq style net detection

Posted on 1998-10-08
5
200 Views
Last Modified: 2013-11-20
I'm trying to find a way to receive some sort of callback or message notification when a network connection as been established.
I know RasConnectionNotification is suppose to do this (I think), but it is only supported by NT and Win98. I'd like to know how icq did this (under 95).
0
Comment
Question by:kisstian
5 Comments
 
LVL 6

Expert Comment

by:snoegler
ID: 1323131
Just a thought:
Why not just polling the connection status every 100 msec:

RasEnumConnection()
for( all connections ) {
  if (RasGetConnectStatus(hRasConn,&rasConnStatus)==0)
    // check for connection
}

As these functions should not consume too much time ( i don't know it exactly ), this is maybe
an easy way.
I think you also could write a RASAPI32.DLL ( or dynamically 'subclass' the functions using
a VxD) to catch calls to RasDial, but this is much more work.
0
 

Author Comment

by:kisstian
ID: 1323132
Thanks! Sounds good.
But I think I will try to write a RASAPI32.DLL to trap calls to RasDial.
The reason is I'm looking for minimal resource hogging while not in use.
0
 
LVL 8

Expert Comment

by:MikeP090797
ID: 1323133
ICQ net detection isn't invoked every 100msecs, it's more like 5-10secs, it won't cause much overload on the system. It doesn't worth writing a VXD
0
 

Accepted Solution

by:
TangCheng earned 100 total points
ID: 1323134
  ICQ's online notify is sent by ICQ server.
   If your friend online his ICQ, His ICQ will send online query message to ICQ server, Then ICQ server will save his online status.
   When your ICQ send query message to server(this message is auto send by your ICQ to query some information every some time) server will return your friend online message to your ICQ.
   You can use socket message spy tool to find it. I use a spy tool(made by myself) to spy ICQ message, then I can get this result.
 
0
 

Author Comment

by:kisstian
ID: 1323135
I will close this question. Seeing how there does not seem be anybody who as actually done some of this stuff before. I guess I'll roll my own little ras.dll and monitor connections/disconnections. But if anybody does get more thoughts on this please drop a line: kisstian@dsuper.net
Thanks all for responding
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Show shut-down message as Windows 8 shuts down. 9 91
xyBalance chalenge 58 93
fizzArray2 challenge 1 79
modThree challenge 4 91
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: Dialogs (2) modeless dialog and a worker thread.  Handling data shared between threads.  Recursive functions. Continuing from the tenth article about sudoku.   Last article we worked with a modal dialog to help maintain informat…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

777 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