Hi everybody ,any help would be appreciated .
on this part of a script i am working on i get an error on the highlighted word ,,,,?
thank you in advance.
# Current price label
def currentPrice = close;
# Use regular variable assignment for priceLabel
if currentPrice >= upper13 then "Price: " + AsText(currentPrice) + " (Between Upper Zone 2 and 3)" else
if currentPrice >= upper68 then "Price: " + AsText(currentPrice) + " (Between Upper Zone 3 and Neutral)" else
if currentPrice >= lower68 then "Price: " + AsText(currentPrice) + " (Neutral Zone)" else
if currentPrice >= lower13 then "Price: " + AsText(currentPrice) + " (Between Neutral and Lower Zone 2)" else
if currentPrice >= lower2 then "Price: " + AsText(currentPrice) + " (Between Lower Zone 2 and 3)" else
"Price: " + AsText(currentPrice) + " (Below Lower Zone 3)";
AddLabel(yes, priceLabel, Color.WHITE);
on this part of a script i am working on i get an error on the highlighted word ,,,,?
thank you in advance.
# Current price label
def currentPrice = close;
# Use regular variable assignment for priceLabel
if currentPrice >= upper2 then "Price: " + AsText(currentPrice) + " (Between Upper Zone 1 and 2)" elsedef priceLabel = if currentPrice >= upper1 then "Price: " + AsText(currentPrice) + " (Above Upper Zone 1)" else
if currentPrice >= upper13 then "Price: " + AsText(currentPrice) + " (Between Upper Zone 2 and 3)" else
if currentPrice >= upper68 then "Price: " + AsText(currentPrice) + " (Between Upper Zone 3 and Neutral)" else
if currentPrice >= lower68 then "Price: " + AsText(currentPrice) + " (Neutral Zone)" else
if currentPrice >= lower13 then "Price: " + AsText(currentPrice) + " (Between Neutral and Lower Zone 2)" else
if currentPrice >= lower2 then "Price: " + AsText(currentPrice) + " (Between Lower Zone 2 and 3)" else
"Price: " + AsText(currentPrice) + " (Below Lower Zone 3)";
AddLabel(yes, priceLabel, Color.WHITE);