NetView scripts ::  Port Listener


 

 

procedure Disconnect;

Disconnects connections without terminationg script's executions. Script execution terminates on any other data transfer function error.

function Recvch: string;

Receives or gets from buffer and returns 1 character. Terminates script if connection is broken.

function Recv: String;

Receives or gets from buffer all accessible data. Terminates script if connection is broken.

function Recvln: String;

Receives or gets from buffer string ending by chr(13)+chr(10). Terminates script if connection is broken.

procedure Send(s: string);

Sends string s to remote side. Terminates script if connection is broken.

procedure SetEcho(EchoOn:integer);

Enable data echo - every received from remote charachter will be immediately echoed to remote side.


function Readln(question: string): string;

Shows dialogue window with text question and text input field. Returns entered by user text.

procedure Writeln(s: string);

Writes a string to PortListener's log..


function GetScriptMode:integer;

Returns 0 for Listener scripts.

procedure SyncScript(I: Longint);

If I=1 then scripts enters critical section, if I=0 - leaves it. Only one script can own scritical section.

procedure WaitMe;

NetView automatically terminates connection after 60 seconds. Use this function to postpone autodisconnection.

function NV_CNAME: string;

Returns local host name.

function NV_REMOTEIP: string;

Returns remote IP.

function NV_PORT: integer;

Returns local socket port number.

function NV_ADDRESS: integer;

Return remote IP address in network byte order.

 


© 2001-2004 Killer{R}   © 2003 VoVaN