I\'m too lazy to fill out my time sheet at work by the end at the end of every month, so I\'ve started adding some functions to our PDF form. Acrobat Pro offers to make advanced
Another way ;)
var aHours = 4.45;
var aHoursInMinutes = (Math.floor(aHours) * 60 )+ ((aHours - Math.floor(aHours)) * 100);
// 285 minutes;
var afromMinutesToHours =
(Math.floor(aHoursInMinutes /60) + ((aHoursInMinutes - (60* Math.floor(aHoursInMinutes /60)))/100));
// 4.45 hours;
var bHours = 0.33;
var bHoursInMinutes = (Math.floor(bHours) * 60 )+ ((bHours - Math.floor(bHours)) * 100); // 33 minutes;
var bFromMinutesToHours =
(Math.floor(bHoursInMinutes / 60) + (( bHoursInMinutes - (60 * Math.floor(bHoursInMinutes / 60)))/100)); // 0.33 hours;
var resultInMinutes = aHoursInMinutes + bHoursInMinutes;
var resultToHours =
(Math.floor(resultInMinutes / 60) + (( resultInMinutes - (60 * Math.floor(resultInMinutes / 60)))/100)); // 5.18 hours;