View Single Post
Old 01-31-2019, 08:30 AM
BjoernH BjoernH is offline
Registered User
Join Date: Mar 2018
Posts: 55
Originally Posted by ekoranyi View Post

It appears that you're trying to supply a range in your if statement. I haven't seen that syntax used before, can you point me to some documentation on its use?

Generally I see ranges with the syntax:
If strMyVal >= 5 And strMyVal <= 20 Then
In your case this would be a little more complex, you won't be able to use the full IP address. You may be able to use the Split function to split the IP and capture only the last octet. You could then compare against the value of the last octet.
Hi Eric, sorry for the delayed reply, I didn't have access to the lab due to upgrades.

I have been able to make it work using this:

'ssh to VMs
	For Each strHosts In Eval(vHost)
    If strHosts = "" Then Exit For

	If doWhat = "start" Then
		If (strHosts = "") OR (strHosts = "") Then
			crt.Sleep 300000
		End If
	End If
    crt.Screen.Send"ssh -q " & strHosts & vbCr
I'll email the entire script if you wish me to do so.

Reply With Quote