Manuais
PHC GO Funções SDK - Dates
 

Dates

This class contains methods and functions related to Dates.
 
 

timezoneDate


Description

Gets a date (including the time) with the correct timezone, based on a specific date.

Return Function

The date (including the time) with the correct timezone.

Parameters


Name Description Type
dt This parameter is optional. If this value is not present, this function will return the current date with the correct timezone. Date

Example


'Gets the current date with the correct timezone 

Dim currentTime as Date = SDK.Dates.timezoneDate()


'Gets an specific date with the correct timezone

Dim myDate as Date = New DateTime(2020, 12, 31)
Dim timeZone as Date = SDK.Dates.timezoneDate(myDate)


timezoneDate


Description

Gets a date (including the time) with the correct timezone, based on a provided date in text (String) format.

Return Function

The date (including the time) with the correct timezone.

Parameters


Name Description Type
dt The date string we want to transform with the current timezone. String

Example


Dim timeZoneDate as Date = SDK.Dates.timezoneDate("31.12.2021 14:30:03")