Skip to content

IServer.IsConnected

property · IServer · cAlgo.API.Internals

DesktopCLICloud

Indicates current connection status with the server

Definition

bool IsConnected {get;}
api.Server.IsConnected: bool

Returns bool

Examples

if (Server.IsConnected)
    Print("Connected to the server, server time: {0}", Server.Time);
else
    Print("Not connected to the server");
if api.Server.IsConnected:
    api.Print(f"Connected to the server, server time: {api.Server.Time}")
else:
    api.Print("Not connected to the server")