Excel make connections with VBA (ping's)

Signaler
Messages postés
2
Date d'inscription
lundi 10 décembre 2007
Statut
Membre
Dernière intervention
11 décembre 2007
-
Messages postés
2
Date d'inscription
lundi 10 décembre 2007
Statut
Membre
Dernière intervention
11 décembre 2007
-
Hi!
I have a button in excel and I have two cells.
-in cell A1 i have a name of computer or an IP.
-in cell B1 i would like to make the result.

If
i have a click in the button, i would like to make a "ping -t
host_name" and put the result "on line" or "off line" in the cell B1.

Is it possible??
very thank's!

2 réponses

Messages postés
3877
Date d'inscription
mardi 19 mars 2002
Statut
Membre
Dernière intervention
23 août 2018
18
You will have to use the Shell function with a >Filename
to write the result in a file.
Then you have to read this file and retreive what you need to put in B1 cell

That's what I think ...

MPi²
Messages postés
2
Date d'inscription
lundi 10 décembre 2007
Statut
Membre
Dernière intervention
11 décembre 2007

oh! it's very important.. If the computer disconnected the B1 puts to Off line and if it's reconnected puts On line.