Forum

News Alerts EA

Hi, i'd like to add some functionality to prevent a bot entering a trade a certain number of minutes after a big news event. In the line before a trade is placed, I have added a call to a sub routine named BigNewsAlert(); In this section, i'd like to check if any of the last 5 candles have got a

Cycle through a list of symbols within my code

string symbols[] = { "GBPUSD" , "USDJPY" , "GBPJPY" , "GBPCAD" , "UK100" , "Ger40" , "US30" , "US100" , "US500" , "XAUUSD" }; First of all, what i'm trying to achieve is a bot which can run on multiple currency pairs. I've defined an array called symbols[] as per the line above. Then I have this

Draw A Rectangle For A Trading Range that Extends Out Into Future Bars

Good evening forum, Below, I have the start of my code for a London Breakout EA which triggers at 8am (London Start). It calculates the dailyResistance and dailySupport from the Asian Session from 12am - 8am. What I would like to do is draw a rectangle on my chart for this area (12am-8am, High-Low)

Add a Decision Matrix to an EA

I have developed an EA that I am hoping to soon use on a prop firm challenge however, I understand that live trading brings a new wave of variables to consider. The first question I would like to ask is, what else (on top of what I am about to present) should be added to a Decision Matrix to aid in

How to Close ALL Trades with a matching Magic Number

Good afternoon forum, I have created a grid bot which trades in both directions (treated separately); the initial buy order and subsequent sell orders have their magic number set as: 1111. The initial sell order and subsequent buy orders have their magic number set as: 2222. Each time an opening

Maths Calculations for Stop Loss

Good morning forum, I'm having a bit of a fuzzy-Monday brain today; hoping somebody can help me with this calculation please. My account is GBP, I'm trading GBP/USD (0.01 lot size) and my leverage is 100:1. If I have a 100,000 GBP account and want to risk 5% per trade, that means my stop loss will

How to Count Number of Open long/short positions

Good afternoon forum, As per the title of this thread, I want to limit my bot from firing in many, many positions into the market. I am happy to compound and build in to positions each time an order is triggered but I would like a maximum limit to be able to manage my maximum exposure. Is there a

Compile Errors (Undeclared Identifier)

Good morning Forum, I have an EA that currently has two variables: buyOrders and sellOrders which increase by 1 each time a new trade is made. I have a maximum number limit which is currently set at 10 buys and 10 sells simultaneously. If a trade closes, then I would like these variables to decrease

Closing Multiple Trades

I rather quickly stumbled across a misconception that I have ignored for a while now, it is finally time to address it. My EA currently fires in a bunch of orders to scale in and out of trades, the problem is: I thought if I have i.e. 3 BUY orders open and I want to close one, I could simply place a

RSI EA trading between certain times each day

Hi forum, As per the title of the thread, if I have a standard RSI EA running that I'd like to run only between a certain period of the day, is there a nice easy way of doing this? What about if I only want new positions to be limited to a time-frame but closing orders may still work? What about if