cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

how to write service for scheduling program according to number of inputs in days,months,Years??

RM12
14-Alexandrite

how to write service for scheduling program according to number of inputs in days,months,Years??

Hello,

            I want to create program and schedule program according to duration dropdown with Days, Months and years .I want to calculate status according to time slot and display status before program start .If there is one program duration is 10 days and time slot is 7 to 8 AM, I want to schedule that program at daily basis

Please refer below attachment and suggest How do I write service  for scheduling program according to number of inputs in days, months, Years?? and How to refresh collection  with refreshing single parameter ??

 

Thanks in advance 

1 REPLY 1
amittal1
10-Marble
(To:RM12)

Hi,

For this kind of requirements, you can use the mechanism of cron string/expressions https://docs.oracle.com/cd/E12058_01/doc/doc.1014/e12030/cron_expressions.htm  and then use thingworx 'Scheduler'.

If you see the Scheduler, you can configure it using cron expression.

Few more links for your reference -

https://www.ptc.com/en/support/article/CS210207 

https://community.ptc.com/t5/ThingWorx-Developers/CRON-String-Format/td-p/621426 

Maybe you have to write your own custom services which are able to take user inputs (from mashups) and then generate the cron string as output, which in-turn you can use to configure schedulers.

With your use case you might also need to create dynamic schedulers (create dynamic things and configure them)

I hope it helps and give you a pointer to start with.

Regards

Aditya

Announcements


Top Tags