Use ROUNDDATETIME function to round the value to hours/minutes before displaying it...
But the variable i am using to display the result is of datatype "DURATION", and this ROUNDDATETIME is of datatype "Datetime"...How to proceed with that?
Use ROUNDDATETIME function to round the value to hours/minutes before displaying it...
But the variable i am using to display the result is of datatype "DURATION", and this ROUNDDATETIME is of datatype "Datetime"...How to proceed with that?
Sorry, I have overlooked this...
Because Duration is just bigint with number of milliseconds, you can use something like:
gduDuration := gduDuration - (gduDuration MOD 60000);
Comments
This function create a DateTime value - how are you displaying it?
Have a look at the help on the FORMAT function and "Format Properties" - Default format 0 seems to be what you need.
Dynamics Nav Add-ons
http://www.simplydynamics.ie/Addons.html
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.
But the variable i am using to display the result is of datatype "DURATION", and this ROUNDDATETIME is of datatype "Datetime"...How to proceed with that?
Default format 0 is again displaying the whole string with milliseconds too...I just want it in days,hrs and minutes...Any other way please?
Sorry, I have overlooked this...
Because Duration is just bigint with number of milliseconds, you can use something like:
to round the duration to minutes etc...
MVP - Dynamics NAV
My BLOG
NAVERTICA a.s.