Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Better date/time functions (for QM < 2.3.2)
#5
Code:
Copy      Help
out
str Length="800.32"
ARRAY(str) arr
tok(Length arr 2 ".")
int ss=val(arr[0]);err
int ms=val(arr[1]);err
long TimeSpan=TimeSpanFromParts(0 0 0 ss ms)
DateTime s=TimeSpan
out s.ToStrFormat("{HH}:{mm}:{ss}.{F}")

I just noticed that this example is converting .32 to .032 for the ms
Needs to use "320" instead of 32.

Good Night,
jimmy Vig


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)