Peter Williams
Peter Williams
Now retired and living in Scotland with great views over the Clyde Estuary.
Like most trying to establish - create or use - profitable EAs
Friends

Add friends via their profile or user search and you will be able to see if they are online

Peter Williams
Added topic EX5 write error
I get the above code at compile time and all I have is this line (the zero's are line and column i.e. no help) EX5 write error         0        0 This is an EA I have compiled
Peter Williams
Added topic Error or NO Error
I have my reporting logs and I sometimes see something like Sell  ticket = 2303414370 request.price = 1.07751 request.volume = 0.16 type = 1 iRes = 1 price = 1.07747 volume = 0.16 is TRUE MyComment = EURUSD_40117263422_S My_error: 4756 Trade
Peter Williams
Added topic Chart TABS not showing
I just created a new installation of an MT5 platform with a new broker.  If I open 2 charts (say) then if I adjust one to full screen then the TAB for the other screen is not visible (or present).  If I minimise the current tab than I see
Peter Williams
Added topic Finding - The selected position is still open.
how to 'track' error CHistoryPositionInfo::HistoryPositionCheck > Error: the selected position is still open. Just don't know how to figure out where this is occurring and how to fix the problem. Should I  be 'closing' something, somewhere
Peter Williams
Added topic What does question mark mean in mt5 code
I have seen this code in the source of an indicator and just wondering what does the question mark ? accomplish and conjunction with the colon : . val[i] = (absValue > 0 ) ? workTrend[i][_TDF]/absValue : 0 ;
Peter Williams
Added topic Can I supress Alerts and Sounds
I am using an indicator (free) called "buy-sell-signals-arrows-indicator". I don't have the source code.  Comments are in Russian but I have tried changing the 3 variables with True or False options and I still get the pop-ups and sound signals
Peter Williams
Added topic My Mistake getting TYPE
TicketType  = myposition.Type();               //A TicketType  = myposition.PositionType();   //B I used  option //A above to get the ticket type
Peter Williams
Added topic Why have my positions Closed?
I feel weird asking this question.. but somehow I have an EA (Mt5) which seems to 'lose' trades. I've been trying to find a problem for the last few days and not getting any nearer.  It's almost as if there is an EA deleting trades! I created
Peter Williams
Added topic Name of Implemented CLASS
Hi, Not sure how accurate my description is but just trying to find out how to find the name from within a class Example: I create a class called DisplayTable I then declare two occurrences of the class Trades & Summary so I can call
Peter Williams
Added topic I get an Error from a Library CHistoryPositionInfo
I keep getting the following error CHistoryPositionInfo::HistoryPositionCheck > Error: the selected position is still open . I presume it generated in the library module code but not quite sure what I should do to avoid the error (or do nothing as
Peter Williams
Added topic use of MT5 Library functions
I am developing the my use of MT5 and trying to get to grips with the libraries and have two questions:- 1. How do I get the bid and ask price using library SymbolInfo. The following code generates Zero 0.00000 for bid and ask but does appear to give
Peter Williams
Added topic Download Report in MT5 from History Tab
Historically in MT4 I used to be able to select which items were displayed in the History window (e.g. Comment). If I selected - say - Comment then it would show in the History Window If I choose to download the History to an  EXCEL file then
Peter Williams
Added topic What Reasons for a Trade to Close so quickly
The following is taken from an excel spreadsheet which I use to examine my 'trades'. [I have removed some details to fit 'better'].  The trade fulfilled my criteria - a breakout from consolidation.  The trade was entered and closed a few
Peter Williams
Added topic How to get the datetime parameters of a Rectangle
I want to get the datetime and prices coordinates of a rectangle price1   = ObjectGetDouble        (ChartNos, objname, OBJPROP_PRICE , 0 );   the abvove works fine for price 1 & 2 ( line_id = 0
Peter Williams
Added topic How to find if a Template Exists before opening a chart
I am trying to establish if a template exists for a specific currency pair before trying to open a new chart from within my MT5 EA then applying the template string FileLocation  = TerminalInfoString ( TERMINAL_DATA_PATH )+ "\\" ;
Peter Williams
Added topic History Orders
I am trying to convert a 'simple' EA from MT4 to MT5 to list History Orders - in particular I want PROFIT, Time OPEN & CLOSE etc I have tried and had partial success shown in the messagebox (using string variable MB) I use the following code void
Peter Williams
Added topic Traiangle coordinates error
I have the following code- for points 1,2 & 3 of a triangle Price1 is declared as double and Time1 as datetime Price1   = ObjectGetDouble        ( 0 ,objName,OBJPROP_PRICE1 , 0 );
Peter Williams
Added topic Heiken Ashi
Hi, I have been reading about the indicator and confused as how to call the indicator correctly.  I have seen the first instance (below)  but not sure the significance of the colors The second statement appears to work fine (i is the
Peter Williams
Added topic Select a Chart from an EA
Hi, I have several charts on my terminal and would like to be able to switch to a specific chart by using a button on my dashboard chart. I can find the chart by scanning through the ChartFirst and Next command and filtered by SYMBOL and PERIOD. Once
Peter Williams
Added topic Chart Window resizing
   long chartID = 0 ;    string msg = "" ;    chartID =   ChartOpen ( "GBPUSD" , PERIOD_M1 );    //msg = msg =+"chartID = "+IntegerToString(chartID);    string mysymbol = ChartSymbol