Need help with BR to convert timezone to UTC

eliana_wise
Tera Contributor

Hi,

I have 4 fields on my change form that needs to be shown UTC time zone; I have gone through majority of the community threads, but couldn't find the solid answer for my request. Please advise.

1 ACCEPTED SOLUTION

Baala T
Mega Guru

Hi Eliana,



If you define a column with the type of "Date", the system will stores value only in UTC. While displaying the value will get converted from UTC to User timezone. If you want to display the value in UTC irrespective of User Timezone, define the column with the type of "String" and store the value in UTC. The String type values will not get converted. It will get displayed as it is.



Use this command to get the current time in UTC


gs.nowNoTZ()


View solution in original post

7 REPLIES 7

Hi Kunal,



I have 4 fields (requested by start, requested by end, Planned start and planned end) on the form; now I need to add 4 other fields that show the value of these as UTC; I will try the script you provided and let you know.



Regards.


Baala T
Mega Guru

Hi Eliana,



If you define a column with the type of "Date", the system will stores value only in UTC. While displaying the value will get converted from UTC to User timezone. If you want to display the value in UTC irrespective of User Timezone, define the column with the type of "String" and store the value in UTC. The String type values will not get converted. It will get displayed as it is.



Use this command to get the current time in UTC


gs.nowNoTZ()


what if i do not want to change the column type to string and send the UTC format of date/time.

Please help

Thanks