Excel make connections with VBA (ping's)

cs_guif Messages postés 2 Date d'inscription lundi 10 décembre 2007 Statut Membre Dernière intervention 11 décembre 2007 - 10 déc. 2007 à 14:24
cs_guif Messages postés 2 Date d'inscription lundi 10 décembre 2007 Statut Membre Dernière intervention 11 décembre 2007 - 11 déc. 2007 à 07:02
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

cs_MPi Messages postés 3877 Date d'inscription mardi 19 mars 2002 Statut Membre Dernière intervention 17 août 2018 23
10 déc. 2007 à 23:06
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²
0
cs_guif Messages postés 2 Date d'inscription lundi 10 décembre 2007 Statut Membre Dernière intervention 11 décembre 2007
11 déc. 2007 à 07:02
oh! it's very important.. If the computer disconnected the B1 puts to Off line and if it's reconnected puts On line.
0
Rejoignez-nous