Schedule job to run only if new queue items at certain time

I am trying to set up a trigger for a bot that will run at a certain time but only if there are new queue items to be processed.

Scheduling for the specific time is a small fix but I don’t want the bot to run every day, I only want it to run at the specific time if there are new items to be processed.

Is this possible? Or will I just have to set the bot to run at the same time every day regardless of whether there are new queue items.

Hi @b.forbes

You can try with Queue Trigger

https://docs.uipath.com/orchestrator/docs/about-triggers

Can instantly start a process upon the trigger creation or whenever you add a new item to a queue. The trigger runs in the environment associated with the selected process.

Check out the Video Link

Hope it will helps

Regards
Gokul

1 Like

Thanks, but this doesn’t really solve my problem. I know you can set triggers for when new queue items are created or for scheduled times, but but my question is to run at a certain time IF new queue items exist.

If there are no queue items I don’t want it to run, regardless of the time schedule trigger

Would setting up a time trigger and a queue item trigger do that?

Hi @b.forbes

You can use the Following condition in If activity or Flow Decision

New DateTime(Now.Year, Now.Month, Now.Day, Now.Hour, Now.Minute, Now.Second) > New DateTime(Now.Year, Now.Month, Now.Day, 07, 59, 0) And New DateTime(Now.Year, Now.Month, Now.Day, Now.Hour, Now.Minute, Now.Second) < New DateTime(Now.Year, Now.Month, Now.Day, 08, 59, 0) And Now.DayOfWeek.ToString <>“Saturday” And Now.DayOfWeek.ToString <>“Sunday”

You can Update the Time and Days in the above condition

Regards
Gokul

1 Like