Medical Dosages

Hello, I am a veterinarian trying to set up a Textblaze that can perform dosages. Example;

Butorphanol {formmenu: name=TorbDose\ ; default=0.2; 0.3; 0.4}mg/kg

Butorphanol (or Torb) has 3 common dosages 0.2 mg/kg, 0.3 mg/kg, and 0.4 mg/kg

I am trying to use the {elseif} command to calculate based on weight and can't seem to make if work.

{if: TorbDose == "0.2"; =kg0.2/10}ml
{elseif: TorbDose == "0.3"; =kg
{elseif: TorbDose == "0.4"; =kg*0.4/10}ml

Where kg is unknown, the doses are variable, but the concentration is 10ml.

Hi @Bond_Vet_Upper_East ,

I'm not sure whether I worked out the calculations properly, but this is one way of doing it:

Patient Weight {formtext: name=weight; default=25}kg
Butorphanol {formmenu: name=TorbDose; default=0.2; 0.3; 0.4}mg/kg

{if: TorbDose == "0.2"}{=weight*0.2/10}ml
{elseif: TorbDose == "0.3"}{=weight*0.3/10}ml
{elseif: TorbDose == "0.4"}{=weight*0.4/10}ml