NexusFi: Find Your Edge


Home Menu

 





sample forex futures code - Easylanguage


Discussion in EasyLanguage Programming

Updated
    1. trending_up 4,914 views
    2. thumb_up 2 thanks given
    3. group 2 followers
    1. forum 4 posts
    2. attach_file 0 attachments




 
Search this Thread
  #1 (permalink)
 highjohn 
Durham, North Carolina
 
Experience: Beginner
Platform: TS
Trading: Futures
Posts: 34 since Mar 2022
Thanks Given: 42
Thanks Received: 3

Hello,

Can someone share a sample code for Forex -futures strategy that includes stop loss/take profit?

This code is not working for forex futures; works for m2k though.

buy next bar 2 contracts at open;

Tried googling but no luck.
Thanks!


Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
CME Raises Energy Futures Margins After Iran-War Volatil …
Commodities
May 26 Deadline Dies at 7.5% as US Strikes Iran During C …
Prediction Markets & Event Contracts
Hormuz Surges From 14% to 26.5% Intraday as Irans Answer …
Prediction Markets & Event Contracts
Second Night of US Strikes Crushes Iran June 15 to 3.6% …
Prediction Markets & Event Contracts
Trump Truth Social Fires Hormuz From 10% to 59% -- Arsen …
Prediction Markets & Event Contracts
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
NexusFi site changelog and issues/problem reporting
13 thanks
Darmok and Jalad at Tanagra
3 thanks
Big Mike in Ecuador
1 thanks
30 Sessions
1 thanks
  #2 (permalink)
Doob
Seattle,Washington,USA
 
Posts: 15 since Nov 2011
Thanks Given: 0
Thanks Received: 13


highjohn View Post
Hello,

Can someone share a sample code for Forex -futures strategy that includes stop loss/take profit?

This code is not working for forex futures; works for m2k though.

buy next bar 2 contracts at open;

Tried googling but no luck.
Thanks!


Just change it a little - you have:

"buy next bar 2 contracts at open;"

Just need to switch it around a little.

Try the following:

buy("buy") 2 contracts next bar at open;

I used Tradestation many years ago - at the time - way too many problems with EasyLanguage and their Support - was poor. I switched over to MultiCharts - PowerLanguage - which was basically the same as EasyLanguage. MultiCharts has 2 versions - MultiCharts PowerLanguage and MultiCharts.NET C#.

Hope that works for you.


Reply With Quote
Thanked by:
  #3 (permalink)
 kevinkdog   is a Vendor
 
Posts: 3,738 since Jul 2012
Thanks Given: 1,918
Thanks Received: 7,485



Doob View Post
Just change it a little - you have:

"buy next bar 2 contracts at open;"

Just need to switch it around a little.

Try the following:

buy("buy") 2 contracts next bar at open;

I used Tradestation many years ago - at the time - way too many problems with EasyLanguage and their Support - was poor. I switched over to MultiCharts - PowerLanguage - which was basically the same as EasyLanguage. MultiCharts has 2 versions - MultiCharts PowerLanguage and MultiCharts.NET C#.

Hope that works for you.


And you might have to enter number of contracts as forex lots - like 100000 contracts for 1 standard Forex lot.


Follow me on X Reply With Quote
Thanked by:
  #4 (permalink)
 highjohn 
Durham, North Carolina
 
Experience: Beginner
Platform: TS
Trading: Futures
Posts: 34 since Mar 2022
Thanks Given: 42
Thanks Received: 3

It didnt work....Will keep trying.


Started this thread Reply With Quote
  #5 (permalink)
 kevinkdog   is a Vendor
 
Posts: 3,738 since Jul 2012
Thanks Given: 1,918
Thanks Received: 7,485


highjohn View Post
It didnt work....Will keep trying.

Can you be a little more specific?

For example, post the code (take out anything proprietary) and then paste any error messages, etc.


Follow me on X Reply With Quote




Last Updated on March 14, 2022


© 2026 NexusFi®, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Downloads - Top
no new posts