Skip to main content
14-Alexandrite
October 1, 2020
Solved

How to write service for assign status for program??

  • October 1, 2020
  • 2 replies
  • 1757 views

Hello,

            I want to show status of  program starting before 2 hrs and  15 min before if program is start then I want to show status is ON  and after finish program it show me Your program  is expired

I have two use case for assign status for program as below 

1) I want to assign program/Batches  for every day

2) Assign program weekly once or twice programs 

 

 please refer below attachment for better understand and suggest how to write service for assign status for program??

 

Thanks in advance

 

Best answer by PaiChung
The simple answer is you probably want to use Schedulers/Timers to create events at certain times or at certain intervals to evaluate what time is it currently vs. what your program is scheduled for. Also if a program actually starts, you can toggle a property to track that it is running/off

2 replies

PaiChung22-Sapphire IAnswer
22-Sapphire I
October 1, 2020
The simple answer is you probably want to use Schedulers/Timers to create events at certain times or at certain intervals to evaluate what time is it currently vs. what your program is scheduled for. Also if a program actually starts, you can toggle a property to track that it is running/off
RM1214-AlexandriteAuthor
14-Alexandrite
October 5, 2020

Thanks for your reply, Can you please suggest in detail How do I used scheduler/timer for calculating status and how to bind ? or Is their possible through service if it Yes then how to write service for assign status for program??

 

16-Pearl
October 5, 2020

Hello @RM12 

 

Please refer following article for your reference:

 

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

https://www.ptc.com/en/support/article/CS243376?&posno=2&q=create%20scheduler%20thingworx&source=search

 

Hope it will answer your query.

 

Thanks

Om Dukiya

Community Manager
October 26, 2020

Hi @RM12.

 

If one of the previous responses answered your question, please mark it as the Accepted Solution for the benefit of others with the same question.

 

Regards.

 

--Sharon