Hi everyone,
I've run into a bit of an issue that you experts may be able to help me solve basically see the Workflow attached the formula inst evaluating the time correctly maybe its something I'm not seeing but any help to resolve this issue is much appreciated I've been banging my head over this issue.
Huge thanks to those who take the time to respond.
Solved! Go to Solution.
Hi @Deano478
You have divided into two formula for checking to different conditions.
The output is stored in the same column deadline.
Many thanks
Shanker V
Hey @Deano478, I've not used this macro before but if you're evaluating the current time, it's a little redundant as it outputs a string which you can't evaluate against a time in this sense.
You may as well just use the native DateTimeNow() function alongside a constructed DateTime using DateTimeToday()+ your target times, to conduct the checks. You'll also need to stack your checks as part of an elseif statement as, if you put different time ranges within the same field, there'll always be multiple that fail and you'll always end up with 'Error'. You could use something along these lines:
Even as I am running the workflow now at 20:05:00, I changed the condition to 21:00:00
Still I get the output as error.
Becos it checks the first condition, writes the output as Deadline1, then checks the second formula and it is failing and hence overwrites as Error.
To overcome the issue, try the below if it works for you.
IF [DateTimeNow] >= '14:00:00' AND [DateTimeNow] <= '21:00:00'
THEN "Deadline 1"
elseIF [DateTimeNow] >= '10:00:00' AND [DateTimeNow] <= '11:00:00' THEN "Deadline 2"
ELSE "Error" ENDIF
@DataNath that's a really neat solution and I just gave it a quick test and it works like charm I never would have come up with a solution like that so thank you for taking the time to respond to my query
User | Count |
---|---|
18 | |
14 | |
13 | |
9 | |
8 |