TimeZoneHelperConvertTimeZoneDateTime Method |
Returns DateTime according timezone information.
Namespace: CMS.GlobalizationAssembly: CMS.Globalization (in CMS.Globalization.dll) Version: 10.0.0
Syntax public static DateTime ConvertTimeZoneDateTime(
DateTime dateTime,
TimeZoneInfo srcTimeZoneInfo,
TimeZoneInfo destTimeZoneInfo,
bool timeZonesRequired = true
)
Parameters
- dateTime
- Type: SystemDateTime
Source datetime - srcTimeZoneInfo
- Type: CMS.GlobalizationTimeZoneInfo
Source timezone - destTimeZoneInfo
- Type: CMS.GlobalizationTimeZoneInfo
Destination timezone - timeZonesRequired (Optional)
- Type: SystemBoolean
If true than the time is converted only if timezones are enabled in the system
Return Value
Type:
DateTimeSee Also