Calculates the Body-Mass Index, based on height and weight.
Syntax
_CalculateBMI(height,weight)
Parameters
Parameters for _CalculateBMI
Parameter | Definition | Data type |
---|---|---|
height | Height of the subject, in centimeters. | Float |
weight | Weight of the subject, in kilograms. | Float |
Returns
BMI measurement (Float).
Notes
weight / (height * height)
Exceptions
An exception of type Argument Exception is returned if the height measurement equals zero. This exception results in:
Example
The following rule is created at the form level on the Vital Signs form, which has items Weight and BMI. The rule also refers to the item Ht in a mapping called RulesLS.
evaluate on Form Submission
value = _CalculateBMI(RulesLS.DSRules.Ht.Value, this.Weight.Value)
always
set this.BMI.Value = value
Copyright © 2013 Oracle and/or its affiliates. All rights reserved. |
---|