I have two questions
I have a date time field set to Prime Meridian time, that I have adjusted to New England’s time zone via the following formula;
{START_DATE/TIME} – 300
When I looked up old archive threads to get the answer to (what is now) my second question, I found a reference to “datedif” as a superior method to make these adjustments. Have I correctly interpreted these old posts, and why is the datedif command different that a simple subtraction?
Checking old archives is supposed to make me feel a little smarter, not raise even more questions!!!!! )
All right, now for my original query.
I’ve calculated the length of a trip, and I want the result to show as HH:MM
I’ve taken the original date time fields and subtracted them
{TRIP TIME}=({END_DATE/TIME} – {START_DATE/TIME}) * 60
and then
{TRIP HOURS} = TRUNCATE ({TRIP TIME},0)
and
{TRIP MINUTES} = ({TRIP TIME} – {TRIP HOURS}) * 60
Then I build my report by putting up the two fields and putting a text field in with the semicolon to make it look like a time
[{TRIP HOURS}] [ : ] [{TRIP MINUTES}]
I have a sneaking suspicion that I’m going to get an “A” for creativity {he says while looking for some small validation from Yoda: } and a “D” for elegance. Surely one of you “Crystal Guru” types has a simpler solution for a Crazy Cunuck like me.
Take Care, all
Rodger
I have a date time field set to Prime Meridian time, that I have adjusted to New England’s time zone via the following formula;
{START_DATE/TIME} – 300
When I looked up old archive threads to get the answer to (what is now) my second question, I found a reference to “datedif” as a superior method to make these adjustments. Have I correctly interpreted these old posts, and why is the datedif command different that a simple subtraction?
Checking old archives is supposed to make me feel a little smarter, not raise even more questions!!!!! )
All right, now for my original query.
I’ve calculated the length of a trip, and I want the result to show as HH:MM
I’ve taken the original date time fields and subtracted them
{TRIP TIME}=({END_DATE/TIME} – {START_DATE/TIME}) * 60
and then
{TRIP HOURS} = TRUNCATE ({TRIP TIME},0)
and
{TRIP MINUTES} = ({TRIP TIME} – {TRIP HOURS}) * 60
Then I build my report by putting up the two fields and putting a text field in with the semicolon to make it look like a time
[{TRIP HOURS}] [ : ] [{TRIP MINUTES}]
I have a sneaking suspicion that I’m going to get an “A” for creativity {he says while looking for some small validation from Yoda: } and a “D” for elegance. Surely one of you “Crystal Guru” types has a simpler solution for a Crazy Cunuck like me.
Take Care, all
Rodger