Forum Discussion
- DonLarsonQrew EliteKelly,
You are going to have to play with the time variable based upon your time zone but this should do the trick.
// Day Variable
var number NumDay = DayOfWeek(Today());
var bool MonToFri = Case($NumDay,
0,false,
1,true,
2,true,
3,true,
4,true,
5,true,
6,false);
// Time Variables
var timeofday CurrentTime = ToTimeOfDay(Now());
var bool EightToEight = If ( ToTimeOfDay("8:00AM")<$CurrentTime and ToTimeOfDay("8:00PM")<$CurrentTime,true, false );
// Formula Check Box
If ( $MonToFri=true and $EightToEight=true, true, false)
------------------------------
Don Larson
Paasporter
Westlake OH
------------------------------- KellyBianchiQrew Assistant CaptainThanks, Don! I'll try this out and let you know =)
------Original Message------
Kelly,
You are going to have to play with the time variable based upon your time zone but this should do the trick.
// Day Variable
var number NumDay = DayOfWeek(Today());
var bool MonToFri = Case($NumDay,
0,false,
1,true,
2,true,
3,true,
4,true,
5,true,
6,false);
// Time Variables
var timeofday CurrentTime = ToTimeOfDay(Now());
var bool EightToEight = If ( ToTimeOfDay("8:00AM")<$CurrentTime and ToTimeOfDay("8:00PM")<$CurrentTime,true, false );
// Formula Check Box
If ( $MonToFri=true and $EightToEight=true, true, false)
------------------------------
Don Larson
Paasporter
Westlake OH
------------------------------- DonLarsonQrew EliteKelly,
I made a mistake in the variable EightToEight. The second half had 8PM being before the Current Time. Here is the simple correction.
var bool EightToEight = If ( ToTimeOfDay("8:00AM")<$CurrentTime and $CurrentTime< ToTimeOfDay("8:00PM"),true, false );
------------------------------
Don Larson
Paasporter
Westlake OH
------------------------------