[LON-CAPA-users] spreadsheet: testing whether a proble is excused
Guy Albertelli II
lon-capa-users@mail.lon-capa.org
Mon, 12 Dec 2005 14:05:31 -0500 (EST)
Hi David,
> I am having some trouble getting loncapa to not assign points if a problem
> is excused. Here is the issue:
>
> If a problem has never been attempted by a student stores_PART_solved is
> undefined and if you include it in any way in a cell calculation, it
> returns "undefined value".
You can do a positive check
if ( [&EXPANDSUM(PART;(stores_PART_solved =~ /excused/ ?1:0))] ) {
# do excused code
} else {
# not excused so do normal calc
}
This will work as long as you haven't excused only a part of a
multipart problem.
--
guy@albertelli.com 0-7-1-8-27,137