Else If Calculation Help Needed - Thanks In Advance!
Hello,
I created an APP that instantly calculates an offer on a property.
All the user has to do is put in the values (dollar amount) in the fields labelled (ARV, CMV and DMV) and choose a "Offer Type" (category field) and the APP will multiple the selected "values" times a drop down field labeled "discount"
The problem I am having is that although the tool worked a few times as I was building the "calculation", it stopped working once I was done and all selections result in an Offer of "0".
**** As a side note because I failed to name the calculation field until I was done, the calculation literally won't work if I change the name "calculation" to the new field name of "Our Offer" NOT SURE IF THIS IS RELATED TO THE ISSUE OR NOT.
Here is what it looks like so far:
if (@Offer Type = "N/A") {calculation = 0} else if (@Offer Type = "Short Sale"){calculation = @CMV * @Discount} else if (@Offer Type = "Owner Finance") {calculation = @CMV * @Discount} else if (@Offer Type = "Lease Option") {calculation = @CMV * @Discount} else if (@Offer Type = "Buy & Hold") {calculation = @CMV * @Discount} else if (@Offer Type = "Wholesale") {calculation = @ARV * @Discount} else if (@Offer Type = "Rehab") {calculation = @ARV * @Discount}
-
Try:
var type = @Offer Type
var discount = @Discount
var cmv = @CMV
var arv = @ARVif (type == "N/A") { 0 }
else if (type == "Short Sale" || type == "Owner Finance" || type == "Owner Lease Option" || type == "etc....." ){ cmv * discount }
else if (type == "Wholesale" ||type == "Rehab") { arv * discount }
Please sign in to leave a comment.
Comments
2 comments