Jan Tarnogrocki / Publications
Forum
MT5 Different Spread Data Window and Market Watch
Hello, On MT5 the spread shown in data window is different to the spread shown on the market watch. Does anybody know why the values differ from each other
Thread safeness
Hello, Within my EA OnTimer() and OnTradeTransaction (...) have read and write access to the same array. Do I need to take care about thread safeness and if so how can I achieve it in MQL5? Thanks in advance
How to get order open price
I am sending an order that is executed and shown in MT5. MqlTradeResult tradeResult = trade.sendBuyMarket( 2 .); OrderSelect (tradeResult.order); double price = OrderGetDouble ( ORDER_PRICE_OPEN ); MqlTradeResult shows 0.0 for price and so does OrderGetDouble(ORDER_PRICE_OPEN): Is
Leaked memory
Hello, when running the code below MT4 prints: 2020.07.28 11:42:00.097 Class EURUSD ,M1: 16 bytes of leaked memory 2020.07.28 11:42:00.097 Class EURUSD,M1: 1 object of type test left 2020.07.28 11:42:00.097 Class EURUSD,M1: 1 undeleted objects left #property strict void OnStart (){ test t
iMAOnArray with MODE_SMMA
Hi there, is iMAOnArray working with MODE_SMMA? Regardless my settings it always returns the values with MODE_SMA. void OnStart () { //--- double buffer[ 3 ]; int shift = 1 ; for ( int i = 0 ; i < 3 ; i++){ buffer[i] = iStdDev ( Symbol (), Period (), 10 , 0 , MODE_SMA , PRICE_CLOSE
MT4 RTD bridge
Hello, I want to send RTD from MQL. In Excel commands can be send using RDT: “=RTD("ProgID,"server","Topic1",..."Topic n")” There you can send e.g. a command to place an order to another RTD server. Now I want not to use Excel, I need a bridge to send RTD commands from my MQL code. I offered it as a
Sleep(100) takes 94 ms or 110 ms
Hi everyone, using Sleep (100) in a loop does not take 100 milliseconds. while (! IsStopped ()) { int GlobalTicker = GetTickCount (); Sleep ( 100 ); Print ( "loop duration after sleep: " , GetTickCount ()-GlobalTicker); I get values above or below: The problem gets even bigger using
Graphical objects in offline chart are not visible
Hello, I am opening an offline chart using tick data: It is not possible to draw graphical objects that use time data. E.G. if I draw a vertical line it is not shown in the chart. It is shown in the list of objects including the time data, but not on the chart. Does someone has any idea how to solve
Desription of arrow misses
Hi All! Why is the description of the arrow not shown? ObjectCreate ( 0 , "Arrow" , OBJ_ARROW_UP , 0 ,Time[ 1 ],Low[ 1 ], 0 , 0 , 0 , 0 ); ObjectSetText( "Arrow" , "description" , 12 , "Times New Roman" ,Green); F8 -> show objects description is activated. Greetings, Jan
Email fishing on mql5
Recently I got some pm asking for my email adresse for obvious fictional reasons like: My friend is interested in your signal. He got problems accessing his mql5 account atm. Can I have your email? He wants to ask you Sam questions. Hm, I almost believed but then my spidersense were suddenly warning