hey guys I am figthing with this script for my sensors and I get this errors:
May-12 9:09:44 PM Error Compiling script BLRadar\BLRadar_MotionSensor9On.vb: '.' expected.
May-12 9:09:44 PM Error Compiling script BLRadar\BLRadar_MotionSensor9On.vb: 'Date' is a type and cannot be used as an expression.
here is the script I am copying from a example they gave me:
blradar.PluginFunction("NewDelayedEventForNoEcho",New Object(){"BLRadar Bathroom Motion Sensor","First Floor Master Bedroom Bathroom Ligthff",3,""})
If hs.IsOffByName("First Floor Master Bedroom Bathroom Ligth")Then
dim ntime as date=TimeValue(dateTime.Now)
if nTime>=TimeValue(date Time.Now)
if ntime>=TimeValue("6:00pm")AndAlso ntime<=TimeValue("9:30pm")then
if hs.IsOnByName("virtual Home Stay")Then
blradar.PluginFunction("ControlDevice",new Object(){"First Floor Master Bedroom Bathroom Ligth","dim",40})
end if
end if
ntime=nothing
end if
end if
Where am I failing???
May-12 9:09:44 PM Error Compiling script BLRadar\BLRadar_MotionSensor9On.vb: '.' expected.
May-12 9:09:44 PM Error Compiling script BLRadar\BLRadar_MotionSensor9On.vb: 'Date' is a type and cannot be used as an expression.
here is the script I am copying from a example they gave me:
blradar.PluginFunction("NewDelayedEventForNoEcho",New Object(){"BLRadar Bathroom Motion Sensor","First Floor Master Bedroom Bathroom Ligthff",3,""})
If hs.IsOffByName("First Floor Master Bedroom Bathroom Ligth")Then
dim ntime as date=TimeValue(dateTime.Now)
if nTime>=TimeValue(date Time.Now)
if ntime>=TimeValue("6:00pm")AndAlso ntime<=TimeValue("9:30pm")then
if hs.IsOnByName("virtual Home Stay")Then
blradar.PluginFunction("ControlDevice",new Object(){"First Floor Master Bedroom Bathroom Ligth","dim",40})
end if
end if
ntime=nothing
end if
end if
Where am I failing???
Comment