[LON-CAPA-users] Custom Response Question
lucasm at ohio.edu
Thu Mar 26 14:18:20 EDT 2020
Could you post sample variables and perhaps an example of the perl you are trying to use?
What does the array look like? What are some typical variables? (or at least analogs if you
don’t want to give away content).
> On Mar 26, 2020, at 2:14 PM, Harding, Gene L <glhardin at purdue.edu> wrote:
> I am trying to do something with a customresponse part that I cannot do really cleanly with normal response types, but am having some trouble evaluating the inputs. The inputs include numeric and text values as part of a single array input. I am having to problems:
> 1. I have not been able to figure out a way, in the “if” statements, to distinguish between a zero (0) answer and a null (“”) answer.
> 2. The string components evaluate to true for any text value. Only numeric entries evaluate as false.
> My questions:
> 1. Is there a way to distinguish between a 0 and a null (i.e., no) response?
> 2. Is it possible to input both numeric and string values in separate textline inputs within one customresponse section?
> Best regards,
> Gene L. Harding, PE
> Associate Professor of ECET
> Purdue University
> LON-CAPA-users mailing list
> LON-CAPA-users at mail.lon-capa.org
Mark Lucas email: lucasm at ohio.edu
252D Clippinger Lab phone: (740)597-2984
Department of Physics and Astronomy fax: (740)593-0433
Athens, OH 45701
More information about the LON-CAPA-users