Click or drag to resize
TimeZoneMethodsDateTimeConvert Method (DateTime, TimeZoneTypeEnum, TimeZoneInfo, TimeZoneInfo)
Convert date time with dependence on time zone type from server date time.

Namespace: CMS.Globalization
Assembly: CMS.Globalization (in CMS.Globalization.dll) Version: 10.0.0
Syntax
C#
public static DateTime DateTimeConvert(
	DateTime dateTime,
	TimeZoneTypeEnum type,
	TimeZoneInfo customTimeZone,
	out TimeZoneInfo usedTimeZone
)

Parameters

dateTime
Type: SystemDateTime
Server date time
type
Type: CMS.GlobalizationTimeZoneTypeEnum
Time zone type
customTimeZone
Type: CMS.GlobalizationTimeZoneInfo
Custom time zone info
usedTimeZone
Type: CMS.GlobalizationTimeZoneInfo
Time zone used for time conversion

Return Value

Type: DateTime
See Also