Re: WaitFor fails while Prompt works (General questions)
Hi,
First thing I noticed is that you use Receive method after the Execute. This would probably hang, since Execute already receives the string and removes it from the buffer. In that case Receive doesn't have anything to receive and causes a hang/timeout.
Since Execute has return type as String, you should better use something like this:
someStringVariable = ssh1.Execute( yourCommand\r\n , your_prompt );
The second thing I notices is that you are trying to execute a command without sending an Enter key. You should add \r\n after the command (as in my above statement).
Can you please try those suggestions? Does that work?
Regards,
Damba
Complete thread:
- WaitFor fails while Prompt works - novanstar, 2008-11-01, 00:06
- Re: WaitFor fails while Prompt works - wodDamir, 2008-11-01, 14:42
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-01, 19:35
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-01, 19:38
- Re: WaitFor fails while Prompt works - wodDamir, 2008-11-01, 20:42
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-03, 23:21
- Re: WaitFor fails while Prompt works - wodDamir, 2008-11-03, 23:24
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-04, 00:35
- Re: WaitFor fails while Prompt works - wodDamir, 2008-11-03, 23:24
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-03, 23:21
- Re: WaitFor fails while Prompt works - wodDamir, 2008-11-01, 20:42
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-01, 19:38
- Re: WaitFor fails while Prompt works - novanstar, 2008-11-01, 19:35
- Re: WaitFor fails while Prompt works - wodDamir, 2008-11-01, 14:42