Am I right that all hidden values are re-calculated after every question?
Simon
On Fri, Feb 3, 2017 at 9:04 PM, William Pride wpride@dimagi.com wrote:
Hi Michel,
Your calculation would be correct when first calculated; however, when the
calculations fire again they also re-trigger all the calculations that are
dependent on them. So, the differential would also be recalculated.
Cheers,
Will
On Fri, Feb 3, 2017 at 8:55 PM, Michel Akkaoui - de Sousa < akkaouim@gmail.com> wrote:
Thanks will for the precision. I didn't know the app re-triggered the
hidden values when the form is completed... I understand we won't be able
to store the value in a case property, but will the proposition works just
to output the time spent reading in the same form though ?
Michel
2017-02-03 18:44 GMT+01:00 William Pride wpride@dimagi.com:
Hi Staci,
Unfortunately I'm not sure that Michel's solution will work (though worth
trying) - the reason being that calculations can fire more than once, for
example they would likely be re-triggered when the form is completed. This
would result in both hidden values just containing the end time of the form.
The easiest solution might be to have this passage be in its own form so
that you can use the form's built in start and end times as your proxies.
You could use end of form navigation
https://confluence.dimagi.com/display/commcarepublic/End+of+Form+Navigation to
make the transition more seamless.
Cheers,
Will
On Fri, Feb 3, 2017 at 3:19 PM, Michel Akkaoui - de Sousa < akkaouim@gmail.com> wrote:
Here is an option :
- Create a multiple choice question named quest_start
- Label : 'Are you ready ?'
- with a single choice that is labeled as 'start'
- with display condition set as 'quick'
- Create a hidden value named 'start' with calculate condition set as
: if(/quest_start = 'start', now(), '')
- Create a question list with two things in it :
- Your text as a label
- A multiple choice question with parameters :
- id : quest_stop
- Only one choice named 'stop'
- Create a hidden value named 'stop' with calculate condition set
as : if(/quest_stop = 'stop', now(), '')
- Create a hidden value or a label with calculate condition set as :
stop - start. It will give you the time
When the reader starts the form, he will encounter the quest-start
question. When he press start, the phone goes automatically to the next
page witch shows the text to be read and the stop button. When stop is
pressed, the phone make the calculation to determine the difference between
time when start and time when stop.
Depending on the phone capabilities and the length of the text to be read,
this stop watch as a few milisecondes of precision. The result of the
substraction is a number of seconds I guess...
Michel
Le vendredi 3 février 2017 14:01:50 UTC+1, Staci Leigh a écrit :
Hi all,
Is there anyway to create a stopwatch function in CommCare? I'm hoping to
track how long it takes for someone to read a small passage. Rather than
using an actual stopwatch and recording the time manually in CommCare, I
wanted to know if there was any start/stop function or workaround I could
use.
Cheers,
Staci
--
You received this message because you are subscribed to the Google Groups
"commcare-users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to commcare-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the
Google Groups "commcare-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/
topic/commcare-users/0rks8RWvg8M/unsubscribe.
To unsubscribe from this group and all its topics, send an email to
commcare-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"commcare-users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to commcare-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"commcare-users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to commcare-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Please excuse any syntax errors. This email was sent from my phone.
07932 107109.
--
You received this message because you are subscribed to the Google Groups
"commcare-users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to commcare-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.