/
WaitForString didn't wait forever [1]
WaitForString didn't wait forever [1]
WaitForString didn't wait forever
Friday, October 23, 2015 2:43 AM - justfool
Hi support,
I tested the xshell_screen.vbs in the installed script folder.
It should be wait for input string "aaa" and then execute command "cat /etc/passwd", but it still executed the command even I didn't input anything.
Does the WaitForString() has default waiting time? I can't find the description in the documents.
Thanks.
Program Ver. : Xshell 5
I tested the xshell_screen.vbs in the installed script folder.
It should be wait for input string "aaa" and then execute command "cat /etc/passwd", but it still executed the command even I didn't input anything.
Does the WaitForString() has default waiting time? I can't find the description in the documents.
Thanks.
Program Ver. : Xshell 5
Re: WaitForString didn't wait forever
Monday, October 26, 2015 4:57 PM - Support
Hello,
WaitForString does not have a timeout. However, there does seem to be an issue in the current version. We will confirm and correct the issue as soon as possible.
Instead of using WaitForString, you can try using the WaitForStrings API.
For example,
Dim indexOfStrs, waitStrs
waitStrs = Array("aaa", "bbb")
indexOfStrs = xsh.Screen.WaitForStrings(waitStrs, 0) => 0 means there is no timeout.
xsh.Screen.Send(indexOfStrs)
Thank you!
Technical Support
Like us on Facebook
Follow us on Twitter
Visit our blog Blog
WaitForString does not have a timeout. However, there does seem to be an issue in the current version. We will confirm and correct the issue as soon as possible.
Instead of using WaitForString, you can try using the WaitForStrings API.
For example,
Dim indexOfStrs, waitStrs
waitStrs = Array("aaa", "bbb")
indexOfStrs = xsh.Screen.WaitForStrings(waitStrs, 0) => 0 means there is no timeout.
xsh.Screen.Send(indexOfStrs)
Thank you!
Technical Support
Like us on Facebook
Follow us on Twitter
Visit our blog Blog
Previous views: 152
Related content
WaitForStrings cannot timeout [2]
WaitForStrings cannot timeout [2]
More like this
not working xsh.Screen.WaitForString("login") xsh.Screen.Send("admin") [1]
not working xsh.Screen.WaitForString("login") xsh.Screen.Send("admin") [1]
More like this
xsh.Screen.WaitForStrings return -1 [2]
xsh.Screen.WaitForStrings return -1 [2]
More like this
WaitForStrings Return Value ERROR [1]
WaitForStrings Return Value ERROR [1]
More like this
xsh.Screen.WaitForStrings in python [1]
xsh.Screen.WaitForStrings in python [1]
More like this
Screen.WaitForStrings broken in latest Xshell6 build [6]
Screen.WaitForStrings broken in latest Xshell6 build [6]
More like this