Announcement

Collapse
No announcement yet.

Can you disable symbol change?

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

  • Can you disable symbol change?

    Hi,

    is there any way to disable symbol change using efs?

    I made a script to do automated trading but yesterday I accidently changed the symbol, which restarted the efs with a different symbol, and I lost all the information stored in the variables such as position size, entry price, indicator values, etc...

    One of the way I came up with to overcome this problem, was to store all the variables to a file during postMain(), and reloading them in preMain() when the symbol is returned to the original. But then I noticed that some indicator values (such as # of trades) can not be recovered by this method.

    Another way I thought of was to jump from postMain() back to main(), depending on whether the trade is open or not. But this might mess up the stack memory since it jumps from one subroutine to another.

    Does anyone have a solution for this? Or is it not possible?

    Thanks,

    ykk

  • #2
    Hello ykk,

    There isn't a method for disabling the symbol change of an advanced chart. Storing your trading information in an external file is your best option for maintaining your symbol-specific data.
    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
      Thank you Jason.

      ykk

      Comment

      Working...
      X