Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

HLCCalculationMode' could not be found

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

    HLCCalculationMode' could not be found

    I am trying to compile my indicator and have this issue.
    HLCCalculationMode' is an enum parameter. How do add a reference of HLCCalculationMode' so I can compile?

    #2
    Hello, thanks for writing in. Can you post the code that is causing this error message?

    Comment


      #3
      The type or namespace name 'HLCCalculationMode' could not be found (are you missing a using directive or an assembly reference?)

      Comment


        #4
        i am trying to find the assembly reference i am trying to extract CamarillaPivot data

        Comment


          #5
          Hi, If you are trying to access the CamarillaPivot drawing tool data, this line should work as indicators/strategies include the DrawingTools namespace:

          protected override void OnBarUpdate()
          {
          double valueR1 = CamarillaPivots(PivotRange.Daily, HLCCalculationMode.CalcFromIntradayData, 0, 0, 0, 20).R1[0];
          }​

          Comment


            #6
            got a little closer PivotRange

            error CS0246: The type or namespace name 'PivotRange' could not be found (are you missing a using directive or an assembly reference?)

            Comment


              #7
              using NinjaTrader.NinjaScript.DrawingTools;
              is in my indicator.

              Comment


                #8
                Hi, this error is coming from the way you are using this drawing object. All of these enums should be defined given you are using the constructor correctly.

                Comment


                  #9
                  Both PivotRange and HLCCalculatioMode are defined in @Pivots.cs,
                  but since they are not defined inside a named namespace, they default
                  to being part of the global namespace.

                  Try using global::HLCCalculationMode in your code.

                  Comment


                    #10
                    CamarillaPivots(PivotRange.Daily,HLCCalculationMod e.CalcFromIntradayData,0,0,0,20)

                    This is what I am Calling. It will work on open source but if I Compile dll it will give the error

                    Comment


                      #11
                      That's because PivotRange and HLCCalculationMode
                      are defined inside @Pivots.cs, so the compiler finds
                      those enums just fine when you compile normally.

                      When you export, did you add the Pivots indicator
                      to your assembly?

                      That should solve your problem.

                      Comment


                        #12
                        Thank you for answering bltdavid I concur with the solution.

                        Comment

                        Latest Posts

                        Collapse

                        Topics Statistics Last Post
                        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                        0 responses
                        557 views
                        0 likes
                        Last Post Geovanny Suaza  
                        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                        0 responses
                        324 views
                        1 like
                        Last Post Geovanny Suaza  
                        Started by Mindset, 02-09-2026, 11:44 AM
                        0 responses
                        101 views
                        0 likes
                        Last Post Mindset
                        by Mindset
                         
                        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                        0 responses
                        545 views
                        1 like
                        Last Post Geovanny Suaza  
                        Started by RFrosty, 01-28-2026, 06:49 PM
                        0 responses
                        547 views
                        1 like
                        Last Post RFrosty
                        by RFrosty
                         
                        Working...
                        X