Gross Profit calculator issue
Trying to determine how to make a gross profit percentage calculation populate in field usgp.

I'm trying to divide usppu/usdcost, multiply by 10, and have the result populate in field usgp. Unfortunately, I'm not getting an error message and the field remains blank.

Note that field usppu populates once uscog (cost of goods) is manually entered and subtracted from usdcost ( i.e. usppu=usdcost-uscog).
Here's what I have so far:
var oFld=this.getField("usppu");
var discount=1;
if(oFld.value!="Off")
{usppu=oFld.value}
if(!this.getField("usppu").value)
{event.value=""}
else
{
event.value=this.getField("usdcost").value/usppu*10;
}
Thank you.
