0

I am trying to create a horizontal line that the user can drag, and the price should be saved as a variable.

StopPrice = input.price(title="Stop Price", defval=1.08, confirm = true)

So here, Im starting at a default value of 1.08,

But I want the line to start at the market price or 15 pips

Ive tried setting

StopPrice = input.price(title="Stop Price", defval=close, confirm = true)

that is not working either.

What can I try?

Nez
  • 39
  • 5

1 Answers1

0

You cannot do this. input.price() expects a const float. You cannot use it with dynamic values.

vitruvius
  • 15,740
  • 3
  • 16
  • 26