IsClient

(RPC Manager Library)

Description: Is Client of a Service. This subroutine returns an indication of whether a particular workstation is a client connected to a service. Returns 1 for the specified service if the specified machine is a client to the machine on which the IsClient() call is made.
Returns: Boolean
Usage: Script Only.
Function Groups: Network
Related to: ConnectToMachine | DisconnectFromMachine | GetServer | GetServersListed | GetStatus | IsPotentialServer | IsPrimaryServer | Register (RPC Manager) | Send | SetRemoteValue
Format: \RPCManager\IsClient(ServiceName, Workstation [, OptGUID])
Parameters:  
ServiceName   
Required. Any text expression giving the name by which the service is known.
Workstation  
Required. Any text expression giving the name or IP address by which the workstation is known to the RPC Manager.
OptGUID
Any optional parameter that provides the GUID for the application in which the service instance is located. The default is the application to which the caller belongs.
Comments:

This subroutine is a member of the RPC Manager's Library, and must therefore be prefaced by \RPCManager\, as shown in the "Format" section. If the application you are developing is a script application, the subroutine call must be prefaced by System\RPCManager\, and the System variable must be declared in AppRoot.src.

The return value from this subroutine is a logical value, if true (1) the workstation is a client connected to the service, if false (0) it is not.
If the 16-byte binary format of the GUID is not known, the GetGUID function may be used to obtain it.

 

To obtain a list of service names for your application, open the Trace Viewer Application, connect to RPC Diagnostics, then open the Services Dialog

Example:

  If 1 Main;
  [
    IfThen(\RPCManager\IsClient("ModemManager", 
           "TestMachine"), 
           ... 
          ); 
  ]

RPC Manager Service