Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Using DLL Interface in TS Easy Language Strategy

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

    Using DLL Interface in TS Easy Language Strategy

    I have installed the els/eld files from NT bin folder and have tried implementing the NTBuyMarket command etc in a script but I get the following error: trying to reference at data to future. Bar reference value: -1. My code works with standard easylanguage buy/sell commands and I can backtest it but for some reason with the NT codes I get the error. Here's a copy of the code command lines:

    ifcurrentbar=1andNTConnected(1)thenbegin
    ifNTMarketPosition("")=0thenbegin
    if MA crosses over MA2thenNTBuyMarket("",1)nextbar;
    end;
    endelsebegin
    if MA crosses under MA2thenNTSellMarket("",1)nextbar;

    end;

    #2
    Hi robninja,

    You are using the function incorrectly. The link below will take you to a sample EL reference strategy. Please take this code and build upon it to get to what your after.

    RayNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    115 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    161 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    83 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by cmoran13, 04-16-2026, 01:02 PM
    0 responses
    127 views
    0 likes
    Last Post cmoran13  
    Started by PaulMohn, 04-10-2026, 11:11 AM
    0 responses
    87 views
    0 likes
    Last Post PaulMohn  
    Working...
    X