Page 1 of 1

Format Time

Posted: Tue Jul 12, 2011 3:49 pm
by siqueira.sistemas
I wonder how do I convert a value in seconds and convert to ("hh: mm: ss").
example:

DT_TEMPO = 10800 ss

display in the report as follows:

3:00:00

Thanks,

Thiago Siqueira

Format Time

Posted: Wed Jul 13, 2011 2:03 am
by HighAley
Hello, Thiago.
[quote="siqueira".sistemas]I wonder how do I convert a value in seconds and convert to ("hh: mm: ss").
example:

DT_TEMPO = 10800 ss

display in the report as follows:

3:00:00[/quote]
For converting value in seconds you must have a variable with digits only.
DT_TEMPO = '10800'

Then in report you can write next string

Code: Select all

{new TimeSpan(0,0,int.Parse(DT_TEMPO))}
You can see it in attached report template.

Thank you.