SetClockSource Method (DynamicTime object)

    Example     Applies To    


The SetClockSource method sets the object to retrieve current time from a particular clock source. Calling this function does NOT automatically set the TimeZoneInfo property of the object to that of the Clock Source. This allows setting the source of current time as a foreign source but wall clock translation of this UTC time according to local or some other location's time zone rules.


object.SetClockSource ClockSource

The SetClockSource method syntax has these parts:

Part Description
object An expression that evaluates to a DynamicTime object.
ClockSource A source reference that provides UTC time for use in relative time string calculations.



The SetClockSource property is used only in relative time calculations. Otherwise, it is ignored. Adding a clock source reference will release any previously set reference time. Adding a reference time to a DynamicTime will release the clock source reference.

Trappable Errors

Only generic errors (such as Out of Memory) may occur.

Enabling Operational Intelligence