My daughter has been swimming year round in Mt. Pleasant, SC and she swims at meets with different pool lengths - 100 meters (Long Course Meters or LCM), 50 yards (Short Course Yards or SCY) and 50 meters (Short Course Meters or SCM).
I'd like to create an ASP page that has input forms to convert times for each pool length to determine how she does each swim. For example, if she swims 1 lap of freestyle in a 25-yard pool and does it in 0:30.00 seconds, that time converts to 0:30.00 x 1.11 + 0.8 seconds for a time of 0:34.10 in a LCM pool.
There are 4 different types of strokes in swimming and slightly different times, below are the conversions I need to do:
50 YARDS SHORT COURSE to LONG COURSE METERS
Butterfly SCY time x 1.11 + .7 seconds
Backstroke SCY time x 1.11 + .6 seconds
Breaststroke SCY time x 1.11 + .7 seconds
Freestyle SCY time x 1.11 + .8 seconds
100, 200 and 400 YARDS SHORT COURS to LONG COURSE METERS
--The same for each stroke but the seconds time doubles each time.
The opposite for LONG COURSE METERS to SHORT COURSE YARDS -
--Instead of adding the seconds, they must be subtacted.
So the script needs:
--A drop down box that has each of the 4 strokes to choose from
--A drop down box that has each of the 3 types of courses to choose from that was the actual pool length swum
--A same drop down choice for the course to convert to
--Multiplied by a hidden number of 1.11
--Addition of a hidden .# seconds determined by the type of stroke
As an example, my daughter swam recently the 100 meter freestyle in 1:17.50 (1 minute, 17 seconds and 50/100's). So to input in a webpage for a calculation:
Event [ ] Course [ ] to [ ] Actual Time [ ] = Converted Time
Event [Free] Course [SCY] to [LCM] Actual Time [1:17.50] = 1:27.60 LCM
I understand ASP scripting and use Dreamweaver MX. However, I've never done a simple ASP calculation script.
My problem is the numeric conversions as in the following:
1:58:98
The 1 is minutes, the 58 is seconds, but the 98 is hundredths.
I don't know how to format such a number especially when the seconds would carry over into the minutes. For instance, a freestyle time of 1:58.98 in a SHORT COURSE YARD pool would increase in conversion to a LONG COURSE METER POOL. I am lost as to how the conversion would take place of the 98 changing over into the seconds column and the seconds colum changing over into the minutes column for a conversion result of:
1:58.98 x 1.11 + 1.6 seconds = 02:13.67
By the way, the 00:00.0 is a swimming numeric format.
Thank you for any assistance.
Dan