How to convert UTC to Eastern time

Primary tabs


Does anyone know how to convert UTC to Eastern time in the DTL?  Input format "YYYYMMDDHHMMSS".

Can I use ConvertDateTime() function? If yes, what value do I use in these fields informat, outformat and outf?

Thank you.




I put in "%K(+5)" in the informat, and it gave me current eastern time, and not the date and tine that I tried to convert.  When I put "%K(+5)" in the outformat, it didn't do anything. The date/time didn't get converted.


The following works for me:

TESTING>write ##class(Ens.Util.FunctionSet).ConvertDateTime("20200228210000",  "%K(0)%q",  "%K(-5)%q")

 I didn't have the correct syntax. It is working now. Thank you very much.