Programmatically know the Time control Status using the GetState method

InogicDyn365CE3 years ago5 Views


Introduction

Often we use Dynamic 365 Time Control when we want to keep track of time based on a certain date.

E.g. Whether a Lead has been qualified before the estimated close date etc.

In this blog, we will see how we can programmatically get the status of the Time Control using form scripting.

To know more about Time control and how to configure it, please follow this link.

In this example, I have configured the Time Control for Case Entity and on the load of the Form it will check the status of the Timer Control and show the Status as a Form Notification.

If the case is resolved before the Resolve By period then it is considered under Success and similarly, if the case is in the Cancelled stage then it is considered as Failure.

GetState method

Syntax: formContext.getControl(“<Your Timer Control Name>”).getState();

The name property of the Timer Control would be the logical name.

GetState method

Code:

To check and show the Timer Control as Form Notification, I have registered a script on Load of the…



Source link

Leave a reply

Join Us
  • X Network2.1K
  • LinkedIn3.8k
  • Bluesky0.5K
Support The Site
Events
February 2025
MTWTFSS
      1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28   
« Jan   Mar »
Follow
Sign In/Sign Up Sidebar Search
Popular Now
Loading

Signing-in 3 seconds...

Signing-up 3 seconds...