Hi there,
You can try the Task Scheduler which might come in handy for your requirements.. The Task Scheduler service allows you to perform automated tasks on a chosen computer. With this service, you can schedule any program to run at a convenient time for you or when a specific event occurs.
About the Task Scheduler https://learn.microsoft.com/en-us/windows/win32/taskschd/about-the-task-scheduler
Task Scheduler for developers https://learn.microsoft.com/en-us/windows/win32/taskschd/task-scheduler-start-page
Here is also a PowerShell script which is worth looking into https://learn.microsoft.com/en-us/answers/questions/232821/anyone-can-help-to-turn-dynamic-dns-server-records.html
------------------------------------------------------------------------------------------------------------------------------------
--If the reply is helpful, please Upvote and Accept it as an answer–