Maintain connection through different forms

Apr 15, 2014 at 12:52 PM
I am using :

client = new SshClient(res.host, int.Parse(res.port), res.user, res.password);
_client.connect();

in FORM1

after successful authentication I want to execute commands in FORM2:

Just like : _client.RunCommand("touch newfile1");


but the error is sshclient is not present in this form.

my question how to maintain a single authentication through out different forms.