Help! Timer
Help! Timer
I need to use timer/counter which helps to generate a function periodically, like quarterly, yearly. Anyone know how to do that?
-
- Super Administrator
- Posts: 4865
- Joined: Wed Mar 05, 2003 3:10 am
If I understand you correctly, you need a function to repeat at a fixed time period.
Try using the Modulo function first.
If that does not do what you want, you will have to use a level. Add some 'days'/'monts'/'minutes' into the stock every time step, monitor the total until it reaches the value you need. Now you will have your trigger. Reset the level at this point and it will start the process again.
Tony.
Try using the Modulo function first.
If that does not do what you want, you will have to use a level. Add some 'days'/'monts'/'minutes' into the stock every time step, monitor the total until it reaches the value you need. Now you will have your trigger. Reset the level at this point and it will start the process again.
Tony.
Thanks
I try MODULO. However, I got this :
"Unable to achieve desired accuracy in integration at time 12"
"Unable to achieve desired accuracy in integration at time 12.002"
I am using a monthly trigger. What is wrong? In addition, the system does not accept "Time" variable in the function. Thanks a lot for your answer.
"Unable to achieve desired accuracy in integration at time 12"
"Unable to achieve desired accuracy in integration at time 12.002"
I am using a monthly trigger. What is wrong? In addition, the system does not accept "Time" variable in the function. Thanks a lot for your answer.
-
- Super Administrator
- Posts: 4865
- Joined: Wed Mar 05, 2003 3:10 am