Announcement

Collapse
No announcement yet.

offsetSeries does not have properties

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

  • offsetSeries does not have properties

    I am trying to set the fastMA to 3 decimal places
    Esignal states that fastMA has no properties
    What I missed

    Study1 = offsetSeries(eval(Type1)(Length1,eval(Source1)(sym (vSymbol))),Offset1);

    fastMA = (Study1.getValue(0));
    fastMA = ((fastMA).toFixed(3)*1);
    sam

  • #2
    Re: offsetSeries does not have properties

    sam
    You need to run a null check on the value of fastMA prior to modifying its properties eg
    if(fastMA==null) return;
    Alex


    Originally posted by sam.burn
    I am trying to set the fastMA to 3 decimal places
    Esignal states that fastMA has no properties
    What I missed

    Study1 = offsetSeries(eval(Type1)(Length1,eval(Source1)(sym (vSymbol))),Offset1);

    fastMA = (Study1.getValue(0));
    fastMA = ((fastMA).toFixed(3)*1);

    Comment


    • #3
      run the null check
      it still comes back with no properties

      if(fastMA == null) return;
      fastMA = Study1.getValue(0);
      fastMA=fastMA.toFixed(2);
      sam

      Comment


      • #4
        sam
        As I indicated in my reply you need to run the null check on the value ie.
        fastMA = Study1.getValue(0);
        if(fastMA == null) return;
        fastMA=fastMA.toFixed(2);

        Once you make this change it should work
        Alex


        Originally posted by sam.burn
        run the null check
        it still comes back with no properties

        if(fastMA == null) return;
        fastMA = Study1.getValue(0);
        fastMA=fastMA.toFixed(2);

        Comment


        • #5
          OK got it this time
          Thanks Alex
          sam

          Comment


          • #6
            sam
            You are most welcome
            Alex


            Originally posted by sam.burn
            OK got it this time
            Thanks Alex

            Comment

            Working...
            X