If you are scanning machines on the network, you are really going to want to
use multiple threads anyway since most of your time is spent waiting for a
response from the remote machine. You should create a class to contain the
data you are looking for and have a procedure in that class be the thread
entry point. Then start multiple threads to do the actual work. If you
really need a timeout (you may not when architected this way, unless ALL
threads get stuck the same way on different machines), then you can always
abort any thread that gets stuck for too long.
Jerry
"Rémi" <(E-Mail Removed)> wrote in message
news:0c0f01c3bf39$200167f0$(E-Mail Removed)...
> Hi,
>
> I'm trying to scan some computer with WMI. All my call
> are a procedure call SCAN(). Something, the procedure get
> stock in a request call to a network computer (the
> computer is always online and i have permissions to
> scan). I'll like to know how to put a timeout value to my
> sub so i can stop the process and begin a scan to another
> computer.
>
> Thanks
|