Command Property  
 

Gets and sets the command that will be executed on the server.

Syntax

object.Command [= command ]

Remarks

The Command property is used to specify a command and its arguments that should be executed on the server. The output of the command will be returned to the application and can be read using the Read or ReadLine method. If no command is specified, then the control will establish an interactive terminal session instead.

The command and its arguments must follow the conventions used by the SSH server, and the command will execute in the context of the authenticated user. The ExitCode property can be used to obtain the numerical exit code of the remote program, if one is available.

Data Type

String

See Also

ExitCode Property, Connect Method, Execute Method, Read Method, ReadLine Method