The conversion from numeric to string is accomplished by dereferencing
the numeric variable within quotes:
Setvar strgvar "!numvar"
To format the time, making sure that the hour and minutes are always two
digits:
Setvar hr rht("0" + "!hphour",2)
Setvar min rht("0" + "!hpminute",2)
Setvar fmt_time hr + ":" + min
-----Original Message-----
From: HP-3000 Systems Discussion [mailto:[log in to unmask]] On
Behalf Of Shahan, Ray
Sent: Tuesday, August 16, 2005 9:42 AM
To: [log in to unmask]
Subject: Numeric to a string in MPE/ix?
Hi all,
I thought, at one time, I had converted a numeric to a string in
MPE, but I either never did, or can't remember how. The problem I'm
trying to solve is to pass a formatted time to another process via the
hphour and hpminute vars. For instance hphour = 6 and hpminute = 10, so
the formatted string to pass would be 06:10.
Any help's greatly appreciated.
TIA,
Ray Shahan
Life is not a journey to the grave with the
intention of arriving safely in a pretty and
well preserved body, but rather to skid in
broadside, thoroughly used up, totally worn out,
and loudly proclaiming:
-- WOW!!! What a Ride
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
|