I think that I have screwed up a script that I didn't understand to begin with... This is a script that used to run a sprinkler cycle every 14 days, the interval being determined by the "mod=" parameter highlighted below in red. I think that I have an unwanted digit in that line, that being the first "4" in highlighted "mod 4= 14"; I'm thinking that should be simply "Mod=14". Can someone confirm that?
Sub Main(ByVal Parms As Object)
Dim StartDate As Date = "4/11/2014" 'Start Date
Dim CompareDate As Date = Now.Date 'Todays Date
If CInt(DateDiff("d", StartDate, CompareDate)) Mod 4 = 14 Then 'Change Mod number to desired interval days
hs.execx10("A3", "on")
End If
End Sub
Sub Main(ByVal Parms As Object)
Dim StartDate As Date = "4/11/2014" 'Start Date
Dim CompareDate As Date = Now.Date 'Todays Date
If CInt(DateDiff("d", StartDate, CompareDate)) Mod 4 = 14 Then 'Change Mod number to desired interval days
hs.execx10("A3", "on")
End If
End Sub
Comment