Jump to content

Duncan

Members
  • Posts

    2
  • Joined

  • Last visited

Duncan's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Hi MayMusic, Thank you. I have inserted a form with a checkbox and a HTML footer with the script, but it's not working. Here is the checkbox... <input name="start" type="checkbox" value="start" /> Start And here is what I've put in the footer HTML... <script> document.getElementById('start').onchange = function (){ if (document.getElementById('start').checked){ document.getElementById('Start_time').value = '[@cbTimestamp]'; } else {document.getElementById('Start_time') = '';} }; </script> Have I set this up wrong. I've attached a couple of screenshots of the setup dialog.
  2. Hello, I have just signed up with Caspio and am creating my first app, but have run into a hurdle I am hoping can be overcome. The app records test cycles and I have a requirement to capture the following fields: Start Weight Start Time (DateTime) Stop Weight Stop Time (DateTime) Mass Consumed (1 - 3) [Calculated Field] Cycle Time in (decimal) hours (4 - 2) [Calculated Field] Consumption Rate (5/6) [Calculated Field] Ideally, I would like the user to be able to click a button or checkbox to capture the date/time, as the form will need to be open when the test starts and we may need to re-start. So, I have two questions please: On a Datapage form, is it possible to add a DateTime stamp to a field using a HTML button or checkbox and some JacaScript? Can I then calculate the difference in hours (digital...i.e. 4.5 is 4hr 30min) and add this to the cycle time field? Any help would be appreciated.
×
×
  • Create New...