Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Condition "half ignored" by strategy

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Condition "half ignored" by strategy

    Hello Everyone,

    I have here a strategy which does not to apply the condition as I think it should. But i am new to scripts and could have made something wrong.

    See the attached picture : when asked to enter when the indicator is rising, the strategy ignores the condition .

    In the title is written "half ignored", because if we add 10 pts in the same condition, the strategy reacts and the order we see in the picture is not entered.

    I also attach a copy of the code that relates to this indicator (which is a simple copy of the available LineReg indicator), just to confirm that every input regarding this indicator are entered right.

    The strategy behaves the same after entering the same parameters in the builder...

    Is anyone able and would care to tell us how this can be ?
    Attached Files
    Last edited by Amedeus; 05-27-2021, 05:58 PM.

    #2
    hey ,

    Ok we are getting closer :
    the name of the bool does not work in the script ! let me explain very quickly:

    after moving the condition in another already working set, the condition was applied.
    after moving the condition back like intially, the condition was not applied.
    after switching the name (variable) of the private bool with another, the condition was applied.

    I did the same operation in the builder with a same result...

    there is one private class bool who does not cooperate, how is this possible ? Is there a way to make this specific name work without redoing the configuration in the builder ?

    Comment


      #3
      Hello Amedeus,

      What is the name of the bool that you are using that is not working? There are certain reserved names of existing NinjaScript properties, if you are using an existing name of a property it likely wont perform as expected.

      I otherwise don't see from the image what the problem surrounding the variable would be.

      I look forward to being of further assistance.

      Comment


        #4
        Hey Jesse, thank you

        I found it.
        the name was used elsewhere and I did not see it. It was not easy to see. It then made one of the 2 enabled bools shut the other.

        I am sorry, rookie mistake.
        have a great week end.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Mindset, 04-21-2026, 06:46 AM
        0 responses
        88 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by M4ndoo, 04-20-2026, 05:21 PM
        0 responses
        134 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Started by M4ndoo, 04-19-2026, 05:54 PM
        0 responses
        68 views
        0 likes
        Last Post M4ndoo
        by M4ndoo
         
        Started by cmoran13, 04-16-2026, 01:02 PM
        0 responses
        119 views
        0 likes
        Last Post cmoran13  
        Started by PaulMohn, 04-10-2026, 11:11 AM
        0 responses
        67 views
        0 likes
        Last Post PaulMohn  
        Working...
        X