Announcement

Collapse
No announcement yet.

Broken DDE link

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

  • Broken DDE link

    Ive managed to get Indicator data linked to Excel. (bollinger bands to be exact)It was running fine until the bollingerbasis data just stopped on all my charts. I hadnt touched anything.
    I have each bollinger line running as a seperate EFS and the other 2 are still showing fine.
    It is showing 0.00 across all the charts I had it running on.
    I tried reloading the EFS, and even restarting my PC, but to no avail.... anyone have any idea why a DDE Link would just suddenly stop working?

  • #2
    Hello maninjapan,

    Are you referring to the same formula code you're working on in this thread, Linking data to excel?
    Jason K.
    Project Manager
    eSignal - an Interactive Data company

    EFS KnowledgeBase
    JavaScript for EFS Video Series
    EFS Beginner Tutorial Series
    EFS Glossary
    Custom EFS Development Policy

    New User Orientation

    Comment


    • #3
      Jason, no. I currently have them setup as 3 seperate DDE links. It was working fine and then suddenly all the values in Excel for bollingerBasis just turned to 0.
      Here is the code.
      var ddebollingerbasis = null;
      var vBOL= new BollingerStudy(20, "Close", 2.0);

      function preMain() {
      setPriceStudy(true);
      setStudyTitle("DDE bollingerbasis");
      setShowCursorLabel(false);
      }

      function main() {
      if (ddebollingerbasis == null) {
      var sName = "bollingerbasis" + getSymbol() + getInterval();
      sName = sName.replace("$", ""); // remove $ from string
      sName = sName.replace("#", ""); // remove # from string
      sName = sName.replace("-","");
      sName = sName.replace(" ", "_") // replace space with underscore
      debugPrintln("DDE Link for Excel =eSignal|EFS!"+sName);
      ddebollingerbasis = new DDEOutput(sName);
      }

      var vbollingerbasis = vBOL.getValue(BollingerStudy.BASIS);
      if (vBOL == null) ddebollingerbasis.set(vbollingerbasis);

      return vbollingerbasis;
      }

      Comment


      • #4
        maninjapan
        The reason you are getting 0 values in Excel is because in the following line of code
        if (vBOL == null) ddebollingerbasis.set(vbollingerbasis);
        you are passing the values to the DDE link only if the value of vBOL is equal to null. Replace that line of code with the following
        if (vbollingerbasis != null) ddebollingerbasis.set(vbollingerbasis);
        which instead passes a value to the DDE link only when the value of vbollingerbasis is NOT equal to null and the formula should work fine
        Alex


        Originally posted by maninjapan
        Jason, no. I currently have them setup as 3 seperate DDE links. It was working fine and then suddenly all the values in Excel for bollingerBasis just turned to 0.
        Here is the code.
        var ddebollingerbasis = null;
        var vBOL= new BollingerStudy(20, "Close", 2.0);

        function preMain() {
        setPriceStudy(true);
        setStudyTitle("DDE bollingerbasis");
        setShowCursorLabel(false);
        }

        function main() {
        if (ddebollingerbasis == null) {
        var sName = "bollingerbasis" + getSymbol() + getInterval();
        sName = sName.replace("$", ""); // remove $ from string
        sName = sName.replace("#", ""); // remove # from string
        sName = sName.replace("-","");
        sName = sName.replace(" ", "_") // replace space with underscore
        debugPrintln("DDE Link for Excel =eSignal|EFS!"+sName);
        ddebollingerbasis = new DDEOutput(sName);
        }

        var vbollingerbasis = vBOL.getValue(BollingerStudy.BASIS);
        if (vBOL == null) ddebollingerbasis.set(vbollingerbasis);

        return vbollingerbasis;
        }

        Comment


        • #5
          Alex, thanks. I ll give it a go and see how it goes. must say Im a bit confused though... I was getting the values fine for a week. and the upper and lower bollingers, which are coded exactly the same, are still working fine.....

          Comment


          • #6
            maninjapan
            You are welcome
            Alex


            Originally posted by maninjapan
            Alex, thanks. I ll give it a go and see how it goes. must say Im a bit confused though... I was getting the values fine for a week. and the upper and lower bollingers, which are coded exactly the same, are still working fine.....

            Comment

            Working...
            X