In an automatic trading system you cannot use graphical elements, hence the error message in the first line of your code…
This is also where the error message in line 30 comes from, you are trying to use a graphical element in an automatic trading system and that is not allowed…
So there are differences between an indicator (may not have buy or sell signals and must end with “return”, etc.) and a trading system (may not contain graphic elements, etc)…
So, make a (right) choice between an indicator and a trading system…
To help us continually offer you the best experience on ProRealCode, we use cookies. By clicking on "Continue" you are agreeing to our use of them. You can also check our "privacy policy" page for more information.Continue