Re: delphi (General questions)
Hi Arno,
Please try something like this in Delphi:
[code]
wodSSHCom1.Connect1;
wodSSHCom1.WaitFor ('regex:[$ #>] $');
wodSSHCom1.DataReady := 0;
memo2.Text := wodSSHCom1.Execute( ls -al + vbLf, 'regex:[$ #>] $');[/code]
Before you execute command using Execute Method you should wait for a prompt to done that. That's why I use WaitFor Method in my code.
More help for WaitFor Method you can find here:
http://www.weonlydo.com/SSH/Help/WODSSHLib~wodSSH~WaitFor.html
When using Execute Method you don't need to call wodSSH Receive Method. Execute Method should return response from server. In your case in memo2.
Let us know how it goes.
Regards,
Drazen
Complete thread:
- delphi - arno, 2008-01-04, 18:15
- Re: delphi - woddrazen, 2008-01-04, 18:34
- Re: delphi - arno, 2008-01-04, 20:45
- Re: delphi - woddrazen, 2008-01-04, 20:48
- Re: delphi - arno, 2008-01-06, 14:33
- Re: delphi - arno, 2008-01-06, 14:33
- Re: delphi - wodDamir, 2008-01-06, 18:08
- Re: delphi - arno, 2008-01-06, 14:33
- Re: delphi - arno, 2008-01-06, 14:33
- Re: delphi - woddrazen, 2008-01-04, 20:48
- Re: delphi - arno, 2008-01-04, 20:45
- Re: delphi - woddrazen, 2008-01-04, 18:34