Page 1 of 1 1
Topic Options
#39531 - 2003-04-25 03:33 PM Is computer online or not ?
happexamendios Offline
Lurker

Registered: 2002-10-09
Posts: 3
Hello,
I would like to know if Kixtart can detect if a computer is online or not... My script must be launched on another computer and must detect others computers to continue. I thought using network dll, but how to use them in kixtart? [Confused]

Top
#39532 - 2003-04-25 03:36 PM Re: Is computer online or not ?
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
it depends entirely do you need to check if the computer is powered or do you need to check also is it hanging (bluescreen maybe) or is it totally on.

pinging, registry-reads, service-status...

all can be done with kixtart. you just need to know have much you want to know.
_________________________
!

download KiXnet

Top
#39533 - 2003-04-25 04:40 PM Re: Is computer online or not ?
Kdyer Offline
KiX Supporter
*****

Registered: 2001-01-03
Posts: 6241
Loc: Tigard, OR
If you choose PING, look for TTL in the result string..

Kent
_________________________
Utilize these resources:
UDFs (Full List)
KiXtart FAQ & How to's

Top
#39534 - 2003-04-25 04:44 PM Re: Is computer online or not ?
AzzerShaw Offline
Seasoned Scripter
****

Registered: 2003-02-20
Posts: 510
Loc: Cheltenham, England
Hi here is a script that Richard H suggested that I use for a similiar problem. It enables yuo to be notifies when the client comes back on-line...hope its of use :

Here is a script that will do it for you:

code:
--------------------------------------------------------------------------------

Break ON$sIPAddress="a.b.c.d"While "true" Shell '%COMSPEC% /C ping -n 1 ' + $sIPAddress + ' | find "TTL=" >/dev/null' If @ERROR=0 $Null=MessageBox("IP Address " + $sIPAddress + " is responding","It's Alive!") Exit 0 EndIf
Sleep(60)
Loop

--------------------------------------------------------------------------------

Set $sIPAddress to the address you want to monitor.

This will check every 60 seconds, and popup a window when the IP address responds then exit.

Change the MessageBox() to "Beep" or "Play" to have a sound instead.
_________________________
If at first you don't succeed, try again. Then quit. There's no use being a damn fool about it. - W.C Fields

Top
#39535 - 2003-04-25 04:45 PM Re: Is computer online or not ?
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
mm...
for ping you have some ready choices (if you use 4.00 or newer kix):
Ping() - checks for reply , or returns ip-address of remote host
WSHPing() - WSH ping routine... no temp files
_________________________
!

download KiXnet

Top
#39536 - 2003-04-25 04:47 PM Re: Is computer online or not ?
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
/dev/null?
eh, don't believe this is going to be run on unix.
'>/dev/null' be translated to '>nul' on wintosh
_________________________
!

download KiXnet

Top
#39537 - 2003-04-25 04:55 PM Re: Is computer online or not ?
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
There are also some typos in AzzerShaw's code. The recommended way is to use UDFs under KiXtart 4.x
_________________________
There are two types of vessels, submarines and targets.

Top
#39538 - 2003-04-25 04:59 PM Re: Is computer online or not ?
AzzerShaw Offline
Seasoned Scripter
****

Registered: 2003-02-20
Posts: 510
Loc: Cheltenham, England
Apologies...
_________________________
If at first you don't succeed, try again. Then quit. There's no use being a damn fool about it. - W.C Fields

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 764 anonymous users online.
Newest Members
ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder, M_Moore
17887 Registered Users

Generated in 0.061 seconds in which 0.029 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org