Quartz.net + Execute on Australian local time
-
04-06-2021 - |
Domanda
I am new to Quartz.NET and I am having a hard time creating an event that will fire daily when its 11AM local time in Australia.
I know I have to use the ScheduleJob method but how do I go about adding the time for Australia? I am not very good with UTC/GMT. Any help on this would be greatly appreciated!
Thank you
Soluzione
You might use the ToUniversalTime
method ( http://msdn.microsoft.com/en-us/library/system.datetime.touniversaltime(v=vs.100).aspx ) to convert local time to UTC. This isn't straightforward but stops you from fiddling with UTC yourself.
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow