MetaTrader 5新功能

桌面版,移动版和网页平台的更新历史

13 五月 2016
新的MetaTrader 5 平台 build 1340:便利的证书转移和改进的策略测试

程序端

  1. 现在用于先进安全连接的证书可以方便地从桌面平台转移到移动程序端。

    交易平台支持扩展认证,通过使用除了密码以外的SSL证书保护交易账户。证书是一个交易服务器上为账户独立生成的文件。该文件是唯一的,没有证书无法完成账户连接。

    在早期的平台版本,所要求的从桌面程序端生成的任何证书都需要手动复制并安装在启用交易账户的MetaTrader 5 iPhone/iPadAndroid 移动设备上。现在,证书可以方便地转移了。


    证书转移过程
    通过交易服务器转移证书:

    • 证书首先在桌面程序端加密:账户所有者使用安全的AES - 256算法为证书加密设置密码。该密码只有使用者知道,而不会发送至服务器。
    • 另外,加密的证书发送至交易服务器,并在此存储直至移动程序端接收,但不会超过一个小时。
    • 若要在移动设备上接收证书,用户必须连接到移动程序端的交易账户。连接后,用户提示导入证书。进行导入时,用户需要指定桌面程序端用于证书加密的密码 。

    证书转移过程非常安全:交易服务器仅用作中间存储,而证书由客户方加密。证书密码不会传到或存储在交易服务器上。
    如何转移证书
    连接您桌面程序端的账户,在快捷菜单中选择"转移证书":



    输入该账户的主密码来确认它属于您。下一步,将其发送到服务器之前,设置一个保护证书的密码。设置的密码至少8位数。

    成功发送证书到服务器之后,打开移动程序端并连接您的账户。您将被立即提示导入证书。确认并输入您在桌面程序端设置的密码。



    您可以在 "关于 — 证书" 部分查看导入证书。
    不久的将来更新的支持证书转移的MetaTrader 5 iPhone/iPad 和 Android平台将会发布。

Tester

  1. 执行挂单,以及SL和TP的更新算法,它将提供更精确的测试条件。视觉测试高级选项。

    交易工具的新功能
    在真实市场中,交易所交易工具图表基于最终价信息生成(最后执行的交易价格)。止损订单也在最终价起动限价订单在卖价和买价起动。所有的订单类型经常在当前市场的卖价/买价执行。策略测试已被更新,现在更好的模拟真实的市场状况:
      之前 之后
    起动 所有挂单类型和SL/TP的卖价/买价 限价订单卖价/买价
    最终止损,止损限价和SL/TP订单
    执行 所有挂单类型和SL/TP的订单指定价格 所有挂单类型和SL/TP的订单起动时的卖价/买价

    让我们考虑Si-6.16 交易品种的示例。起动价格的新买入止损订单 = 设定72580 而当前价格是:Bid=72570,Ask=72572,Last=72552。在价格流新收到的当前价格:

    • Bid=72588
    • Ask=72590
    • Last=72580


    起动交易工具止损订单的是最终价。所以价格流中收到的Last price=72580 激活买入止损订单。在早期版本中,相同价格将用于执行该订单。这个行为是错误的,因为市场中没有Ask=72580 执行买入交易。


    当前 Ask=72590 被用于更新的tester版,所以买入止损订单在该价格执行。Tester 中新的交易执行算法更接近真实市场条件。使用之前算法时,交易操作将以非市场价执行,这将会导致测试结果不准确。

    其他工具的新功能
    其他工具的算法没有改变:用于所有挂单类型,以及SL和TP 的卖价/买价。然而,执行模式已经改变:在早期版本中,以订单中指定的价格执行订单。现在使用根据订单激活时间的市场卖价和买价。

    视觉测试的新功能
    视觉测试期间,柱形图的最高买价线和最低卖价线现在显示在tester。在该图表上,更方便测试交易所工具的EA交易,因为这种工具的柱形图以及起动的订单都是根据最终价完成,而市场操作以卖价和买价执行。



    视觉测试图表的新选项:导航到指定日期。双击图表,输入想要的日期和时间。也可以导航到任何订单或交易:在交易,历史或操作选项卡双击相应的交易操作。
  2. 扩展测试开始前加载的有关价格和报价历史的日志记录信息。现在日志包含有关历史加载完成的信息,以及下载的数据量和花费的时间:
    2016.05.10 12:47:53    Core 1    5.10 Mb 已处理历史记录 0:00.842
    2016.05.10 12:47:53    Core 1    GBPUSD:历史同步完成 [5225 Kb]


MQL5

  1. 修正CopyTicks函数的行为:它将返回比要求更低的报价。
  2. 修正生成的模板函数。
  3. 更新文档。

更新内容将通过LiveUpdate系统提供。

12 五月 2016
MetaTrader 5 网页平台:现已提供测试

MetaTrader 5 网页平台测试版现已发布。新产品将网页程序端的便利性和跨平台的特性与MetaTrader 5桌面版的优势相结合 – 高速,支持多元化市场和扩展的交易功能。

MetaTrader 5 网页平台可在MQL5.community上使用,它允许交易者从任何浏览器和操作系统,包括Windows,Mac和Linux,执行金融市场的交易操作。您只需要一个网络连接。不需要额外的软件。

测试版拥有以下特性:

  • 锁仓系统
  • 30种技术指标
  • 24种分析对象
  • 一整套的 MetaTrader 5 交易订单
  • 41 种界面语言
发布测试版的目的在于提供全球化的公开测试,使交易者能够评估它的新性能。
22 四月 2016
新版MetaTrader 5 build 1325:锁仓选项和实时报价测试

程序端

  1. 我们已经添加第二个账户系统—锁仓,该新系统能够扩大零售外汇交易者的可能性。现在,每个交易品种可以有多个持仓,包括反向持仓。这就为实施基于所谓“锁定”的交易策略铺平道路 — 如果价格对交易者反向移动,他们可以打开一个反向持仓。

    由于新系统类似于在MetaTrader 4中使用的系统,它将被交易者所熟知。与此同时,交易者将能够享受第五代平台版本的全部优势 — 使用多个交易填写订单 (包括部分填充),支持MQL5 云网络的多货币和多线程测试等等。

    现在,您可以使用一个账户从事依附于净额系统,一个工具仅允许一个持仓的市场交易,以及在同一个平台使用另一个账户从事外汇交易和使用锁仓。

    新建锁仓账户,查看持仓账户类型
    持仓账户系统设置在一个账户水平,并显示在程序端窗口标题和日志:



    要新建一个锁仓模拟账户,请启用相应选项: 




    净额系统
    通过这个系统,在同一时间,一个交易品种您只能有一个普通持仓:

    • 如果一个交易品种有一个持仓,同向执行一个交易会提高该持仓的交易量。
    • 如果反向执行交易,那么现有的交易量可能减少,持仓可能会被关闭 (成交交易量等于持仓交易量时) 或撤销 (如果反向成交的交易量大于当前持仓)。

    这没关系,导致反向交易的是 — 已执行的市场订单或触发的挂单。

    下面示例显示了执行两个每笔0.5手的EURUSD买入交易:


    执行这两个交易即是1手的一个普通持仓。

    锁仓系统
    通过这个系统,您可以一个交易品种拥有多个持仓,包括反向持仓。

    如果您有一个交易品种的持仓,执行一个新交易(或触发挂单),那么会另外建立一个新持仓。您当前持仓不会改变。

    下面示例显示了执行两个每笔0.5手的EURUSD买入交易:


    执行这些交易则会新建两个独立的持仓。

    新交易操作类型 - Close By
    新的交易类型已经被加入锁仓账户 — 通过反向持仓来平仓。这个操作允许在单一交易品种关闭两个反向的持仓。如果反向持仓手数不同,那么两个持仓中只有一个订单保留持仓。其交易量将等于平仓手数的差异值,而持仓方向和开盘价将匹配平仓的更大(交易量)。

    相比单独关闭两个持仓,关闭反向持仓允许交易者保留一个点差:

    • 单独平仓情况下,交易者必须支付一个点差两次:以低价位(卖价)关闭买入持仓和高价位关闭卖出持仓(买价)。
    • 使用反向持仓时,第二个持仓的开盘价被用于关闭第一个持仓,而第一个持仓的开盘价被用于关闭第二个持仓。


    在后面那种情况下,下单"close by" 订单。平仓信息在该评论指明。一组反向持仓通过两个"out by"交易关闭。关闭两个持仓得到的总利润/亏损只在一个交易中指明。


  2. 除了支持锁仓外,新版平台还为从MetaTrader 4迁移账户提供了更广泛的机会。现在,交易商可以自动转移账户到MetaTrader 5,包括所有的操作:持仓和挂单,完成交易历史。

    首次连接从MetaTrader 4迁移的账户时会打开一个欢迎对话框。在迁移过程中,数据的传输安全加密。若要开始使用,请指定您在MetaTrader 4使用的账户密码,然后设置一个新密码。



    连接一旦成功,您将可以继续使用您的账户,就好似它已在MetaTrader 5持仓。来自MetaTrader 4所有交易的完整历史记录会自动添加到新账户。

    订单和持仓(包括历史订单)标签在导入过程中不会保留,因为从MetaTrader 4导入一个历史记录可能相当于MetaTrader 5中的4个历史操作。所有的交易记录都会分配新的标签。

    根据交易商导入的方式可以保留或替代账号。

  3. 程序端:新增聊天功能。现在,您可以与您的MQL5.community朋友和同事进行交流沟通了。聊天显示了您MQL5 账户的所有个人信息。开始沟通时,可以直接从聊天窗口登录您的账户或通过平台设置登录:工具 -> 选项 -> 社区。




  4. 程序端:简化的模拟账户创建对话框,添加创建锁仓账户的能力。您不再需要填写大表格。只需指定基本数据和选择交易参数:账户类型,入金,杠杆和锁仓功能。




  5. 添加自动分配模拟账户以便快速启动。如果平台还没有账户,第一个可用交易服务器上的模拟账户会在启动时分配。成功打开后,账户连接马上建立。

  6. 现在,每个持仓有一个标签 — 一个独一无二的号码。它通常匹配用于持仓的订单标签,除非标签更改为服务器上服务操作的结果,例如,收取重新持仓库存费时。程序端更新后,标签被自动分配到所有可用持仓。



  7. 修正建立导致持仓反转的市场订单时设置的止损和获利水平。直到目前,没有适当的水平设置给新持仓。
  8. 修正单击交易面板上显示4位及更多小数位的价格。
  9. 修正打印预览窗口的新闻显示。
  10. 修正报价图表显示。
  11. 修正程序端紧急关闭后打开市场深度。
  12. 添加如果显示单击交易面板控制元素时允许市场订单的检查。
  13. 假设大量新建订单和持仓情况下,优化利润和预付款计算。
  14. 添加用户界面的马来语翻译。
  15. 完全修改后的用户手册。新设计,交互式屏幕截图和嵌入式视频 — 以最大的方便性了解MetaTrader 5的交易:



  16. 修正"前景图表"模式下图形对象的展示。

Tester

  1. 新增在实时报价历史测试自动交易和技术指标的能力。

    真实报价的测试和优化尽可能地接近实际情况。代替基于分钟数据生成的报价,现在可以使用交易商积累的真实报价。有许多来自交易商和流动量提供商的报价。

    若要开始测试或优化真实报价,请在策略测试选择相应的模式:



    报价数据的大小要比分钟数据大。第一次测试期间,下载它可能需要较长的世界。按月下载的报价数据被存储在TKC文件,在 \bases\[trade server name]\ticks\[symbol name]\。
    测试真实报价
    当测试一个真实报价时,一分钟柱内的点差可能改变,因此生成一分钟报价时,使用相应柱固定的点差。

    如果一个交易品种显示市场深度,那么柱形图会严格根据最后执行的交易价格(Last)来构建。否则,tester会根据收盘价首次尝试构建柱形图,如果这些价格不存在,则使用卖价。无论收盘价是否存在,所有报价上都会触发OnTick 事件。

    请 注意,即使根据收盘价构建图表,交易操作也会始终根据卖价和买价执行。例如,如果仅使用开盘柱进行交易的EA交易(例如内置移动平均指标)收到了收盘价信 号,它以另一个价格执行一个交易(取决于方向的买价或卖价)。如果使用“每一报价”模式,柱形图通过卖价构建,而交易通过卖价和买价执行。买价作为卖价+ 对应分钟柱固定点差来计算。

    如果交易品种历史有一个无报价数据的分钟柱,tester 在“每一报价”模式下生成报价。这允许测试一定时期内的EA,以防交易商报价数据的不足。如果交易品种历史记录没有分钟柱但是有适当的分钟报价数据,那么这些报价可以忽略。分钟数据被认为更可靠。

    在MQL5 云网络测试真实报价
    测试真实报价现在不仅可用于本地和远程代理,还可以通过MQL5 云网络实现。可能需要几个月的策略优化,通过数千台电脑的计算能力,可能几个小时就可完成。

    若要使用MQL5云网络测试策略,请启动使用云代理:



    使用MQL5云网络测试真实报价可以消耗大量的数据。这可以显著影响使用网络能力的支付。
  2. 修正几个交易品种类型上妨碍计算手续费的错误。
  3. 修正根据相应持仓的专家字段填写激活SL/TP得到的交易订单的专家字段。之前,不填写这些内容。
  4. 修正切换到通常状态并进一步优化结果的标签。
  5. 修正计算和显示“轨道线”指标。
  6. 优化可视化测试。
  7. 优化了大量新建订单和持仓时的利润和预付款计算。
  8. 优化高频交易期间的交易操作。
  9. 现在,如果是非关键交易品种属性请求(不需要当前报价),则不执行历史同步。例 如,SYMBOL_SELECT,SYMBOL_DIGITS,SYMBOL_SPREAD_FLOAT,SYMBOL_TRADE_CALC_MODE,SYMBOL_TRADE_MODE,SYMBOL_TRADE_STOPS_LEVEL,SYMBOL_TRADE_FREEZE_LEVEL,SYMBOL_TRADE_EXEMODE 等等。之前,非关键交易品种历史记录在其属性的任何请求下都会同步。
  10. 修正按照每年比例计算库存费。ixed calculation of swaps as a percentage per annum.

MQL5

  1. 可执行文件EX5的格式已经变成实施MQL5语言的新功能和MetaTrader 5的新锁仓选项。通过之前版本MetaEditor编译的所有EX5应用程序更新后将能正常工作,例如正向兼容性完全保留。

    build 1325及以上版本编译的EX5程序将无法在旧版构建的程序端运行 - 不支持反向兼容性。

  2. 添加支持抽象类和纯虚函数。

    抽象类用于创建您期待用于创建更具体派生类的通用实体。抽象类仅能用作一些其他类的基本类,这就是不能创建抽象类类型对象的原因。

    至少包含一个纯虚拟函数的类是抽象类。因此,从抽象类派生出来的类必须实施其所有纯虚拟函数,否则它们也将是抽象类。

    虚拟函数通过使用pure-specifier语法声明为"pure"。考虑CAnimal类的示例,它的创建只能提供常用功能 – CAnimal类型的对象对于实际使用太普通。因此,CAnimal 是一个很好的抽象类示例:
    class CAnimal
      {
    public:
                          CAnimal();     // 构造函数
       virtual void       Sound() = 0;   // 纯虚拟函数
    private:
       double             m_legs_count;  // 动物脚的数量
      };
    这里Sound() 是一个纯虚拟函数,因为它声明为纯虚拟函数PURE (=0)的说明符。

    纯虚拟函数只是为设置PURE说明符的虚拟函数:(=NULL) 或(=0)。抽象类声明和使用的示例:
    class CAnimal
      {
    public:
       virtual void       Sound()=NULL;   // PURE 类函数,应被覆盖在派生类中,CAnimal 现在是抽象类,不能创建
      };
    //--- 派生自一个抽象类
    class CCat : public CAnimal
     {
    public:
      virtual void        Sound() { Print("Myau"); } // PURE被覆盖,CCat 不是抽象类,可以创建
     };
    
    //--- 错误使用的例子
    new CAnimal;         // 'CAnimal' 错误 - 编译器返回"不能实例化抽象类"的错误
    CAnimal some_animal; // 'CAnimal' 错误 - 编译器返回"不能实例化抽象类"的错误
    
    //--- 正确使用的示例
    new CCat;  // 没有错误 - CCat 类不是抽象类
    CCat cat;  // 没有错误 - CCat 类不是抽象类
    抽象类的限制
    如果抽象类的构造函数调用一个纯虚拟函数(直接或间接),结果是未定义的。
    //+------------------------------------------------------------------+
    //| 抽象基类                                                          |
    //+------------------------------------------------------------------+
    class CAnimal
      {
    public:
       //--- 纯虚拟函数
       virtual void      Sound(void)=NULL;
       //--- 函数
       void              CallSound(void) { Sound(); }
       //--- 构造函数
       CAnimal()
        {
         //--- 虚拟类函数的显式调用
         Sound();
         //--- 隐式调用(使用第三个函数)
         CallSound();
         //--- 构造函数或析构函数始终调用自己的函数,
         //--- 即使它们是虚拟函数并且已经被派生类中已调用的函数所覆盖
         //--- 如果调用的函数是纯虚拟函数
         //--- 调用会引起“纯虚拟函数调用”的关键的执行错误
        }
      };
    然而,抽象类的构造函数和析构函数可以调用其他成员函数。

  3. 添加支持函数指针来简化事件模式的安排。

    若要声明一个函数指针,请指定"函数指针"类型,例如:
    typedef int (*TFunc)(int,int);
    现在,TFunc是一种类型,可以声明函数的变量指针:
    TFunc func_ptr;
    func_ptr 变量可以存储函数地址以便稍后声明:
    int sub(int x,int y) { return(x-y); }
    int add(int x,int y) { return(x+y); }
    int neg(int x)       { return(~x);  }
    
    func_ptr=sub;
    Print(func_ptr(10,5));
    
    func_ptr=add;
    Print(func_ptr(10,5));
    
    func_ptr=neg;           // 错误:neg 不是 int (int,int) 型
    Print(func_ptr(10));    // 错误:应该有两个参数
    函数指针可以被存储并作为参数传递。您不能得到非静态类函数的指针。

  4. MQL5:MqlTradeRequest 有两个新字段:

    • position — 持仓标签。锁仓模式交易下为了明确识别而改变和关闭持仓时来填写。在净额系统,填写字段不会有任何影响,因为持仓只识别一个交易品种名称。
    • position_by — 反向持仓标签。它用于通过反向持仓平仓时(打开一个同名但反向的交易品种)。该标签仅用于锁仓系统。

  5. 添加TRADE_ACTION_CLOSE_BY 值到 ENUM_TRADE_REQUEST_ACTIONS 交易操作类型枚举 — 通过反向持仓。该标签仅用于锁仓系统。

  6. 添加交易操作标签到适当订单,交易和持仓属性的枚举:

    • 添加ORDER_TICKET 属性到 ENUM_ORDER_PROPERTY_INTEGER — 订单标签。每个订单会分配一个独一无二的号码。
    • 添加 DEAL_TICKET 属性到 ENUM_DEAL_PROPERTY_INTEGER — 交易标签。每笔交易会分配一个独一无二的号码。
    • 添加POSITION_TICKET 属性到 ENUM_POSITION_PROPERTY_INTEGER — 持仓标签。每个新持仓会分配一个独一无二的号码。它通常匹配用于持仓的订单标签,除非标签更改为服务器上服务操作的结果,例如,收取重新持仓库存费时。若 要找出一个用于持仓的订单,请应用POSITION_IDENTIFIER 属性。POSITION_TICKET 值对应MqlTradeRequest::position。

  7. 添加ORDER_TYPE_CLOSE_BY 值到 ENUM_ORDER_TYPE 订单类型枚举 — close by 订单。
  8. 添加ORDER_POSITION_BY_ID 值到 ENUM_ORDER_PROPERTY_INTEGER 订单属性枚举 — ORDER_TYPE_CLOSE_BY 类型订单的反向持仓标识符。
  9. 添加DEAL_ENTRY_OUT_BY 值到 ENUM_DEAL_ENTRY 交易方向枚举 — 由close by操作执行交易。
  10. MqlTradeTransaction 也有两个类似的字段:


    • position — 由交易活动影响的持仓标签。这里填写处理市场订单(TRADE_TRANSACTION_ORDER_* except TRADE_TRANSACTION_ORDER_ADD,在这里持仓标签尚未分配) 和订单历史(TRADE_TRANSACTION_HISTORY_*)相关的交易活动。
    • position_by — 反向持仓标签。它用于通过反向持仓平仓时(打开一个同名但反向的交易品种)。这里只填写通过反向持仓而平仓的订单 (close by) 和通过反向持仓而关闭的交易 (out by)。

  11. 添加PositionGetTicket 函数 — 根据持仓列表的索引返回一个持仓标签和使用PositionGetDouble, PositionGetInteger 和PositionGetString函数自动选择持仓用于进一步工作。
    ulong  PositionGetTicket(
       int  index      // 持仓列表索引
       );

  12. 添加PositionSelectByTicket 函数 — 通过指定标签为进一步工作选择一个持仓。
    bool  PositionSelectByTicket(
       ulong   ticket     // 持仓标签
       );

  13. 添加SYMBOL_MARGIN_HEDGED 值到 ENUM_SYMBOL_INFO_DOUBLE 交易品种属性枚举 — 合约大小或一手锁仓预付款(一个交易品种的反向持仓)。

    • 如果一个交易品种指定了初始预付款 (SYMBOL_MARGIN_INITIAL),锁仓预付款被指定为绝对值(以货币计算)。
    • 如果没有设置初始预付款(等于0),预付款计算中将被使用的合约大小在SYMBOL_MARGIN_HEDGED指定。预付款使用对应一个交易品种类型 (SYMBOL_TRADE_CALC_MODE)的等式计算。

    锁仓预付款计算的详细信息会在MetaTrader 5 交易平台帮助中说明。

  14. 添加ACCOUNT_MARGIN_MODE 值到 ENUM_ACCOUNT_INFO_INTEGER 账户属性枚举 — 当前交易账户的预付款计算模式:

    • ACCOUNT_MARGIN_MODE_RETAIL_NETTING — 用于净额模式账户持仓时的场外交易市场(一个交易品种一个持仓)。预付款计算基于交易品种类型 (SYMBOL_TRADE_CALC_MODE)。
    • ACCOUNT_MARGIN_MODE_EXCHANGE — 用于交易所市场。预付款计算基于交易品种设置中指定的折扣。折扣由交易商设置,但是它们不能低于交易所设置的值。
    • ACCOUNT_MARGIN_MODE_RETAIL_HEDGING — 用于独立持仓账户场外交易市场(锁仓,一个单一交易品种可以有多个持仓)。预付款计算基于交易品种类型 (SYMBOL_TRADE_CALC_MODE)。也要考虑锁仓预付款大小 (SYMBOL_MARGIN_HEDGED) 。

  15. 添加TERMINAL_SCREEN_DPI 值到 ENUM_TERMINAL_INFO_INTEGER 客户端属性枚举 — 分辨率显示数据通过每英寸的点数来衡量 (DPI)。该参数的信息允许指定图形对象的大小,这样它们在不同分辨率的显示器上看起来一样。

  16. 添加 TERMINAL_PING_LAST 值到 ENUM_TERMINAL_INFO_INTEGER 客户端属性 — 以微秒计算交易服务器最后得到的ping值。一秒等于一百万微秒。

  17. 修正返回SendFTP函数调用结果。之前,成功发送后返回 FALSE 而不是 TRUE。
  18. 修正偶尔导致"违规访问"执行错误的StringConcatenate函数错误。
  19. 修正使用模板函数时发生的几个错误。
  20. 添加为打印,警示和评论功能显示超过4000字符行的能力。
  21. 修正ArrayCompare函数通过不同于开始时期的初始持仓变化来比较数组和函数本身时产生的错误。
  22. 添加支持标准库的锁仓功能:

    CPosition
    添加类函数:

    • SelectByMagic — 根据魔幻数选择持仓和进一步工作的交易品种。
    • SelectByTicket — 通过进一步工作的标签选择持仓。

    CTrade
    添加类函数:

    • RequestPosition — 收到持仓标签。
    • RequestPositionBy — 接收反向持仓标签。
    • PositionCloseBy — 通过反向持仓支持标签平仓。
    • SetMarginMode — 根据当前账户设置来设置预付款计算模式。

    添加重载类函数:

    • PositionClose — 平仓标签。
    • PositionModify — 修改持仓标签。

    CAccountInfo
    改变类函数:

    • MarginMode — 接收预付款计算模式。直至目前,类函数的工作类似于新的StopoutMode 类函数。
    • MarginDescription — 接收预付款计算模式为字符串。直至目前,类函数的工作类似于新的StopoutModeDescription类函数

    添加类函数:

    • StopoutMode — 接收最小预付款水平规范模式。
    • StopoutModeDescription — 接收最小预付款水平规范模式为字符串。

    CExpert
    添加类函数:

    • SelectPosition — 为进一步工作选择持仓。

  23. 对标准程序库添加一些改进。
  24. 修正卸载DLLs。
  25. 添加支持模板类构造函数。

信号:

  1. 修正几个交易信号窗显示错误。

MetaEditor

  1. 修正“全字匹配”模式下文件的搜索词。
  2. 添加在所需文件的编译结果行上双击移动到一个文件。
  3. 修正显示Windows XP中的一些控制元素。
更新文档。
1 四月 2016
MetaTrader 5 平台 Build 1295

程序端

  1. 为了扩展零售外汇交易者的可能性,我们添加了第二账户系统 — 锁仓。现在,每个交易品种可以有多个持仓,包括反向持仓。这就为实施基于所谓“锁定”的交易策略铺平道路 — 如果价格对交易者反向移动,他们可以打开一个反向持仓。

    由于新系统类似于在MetaTrader 4中使用的系统,它将被交易者所熟知。与此同时,交易者将能够享受第五代平台版本的全部优势 — 使用多个交易填写订单 (包括部分填充),支持MQL5 云网络的多货币和多线程测试等等。

    现在,您可以使用一个账户从事依附于净额系统,一个工具仅允许一个持仓的市场交易,以及在同一个平台使用另一个账户从事外汇交易和使用锁仓。

    新建锁仓账户,查看持仓账户类型
    持仓账户系统设置在一个账户水平,并显示在程序端窗口标题和日志:



    要新建一个锁仓模拟账户,请启用相应选项:




    净额系统
    通过这个系统,在同一时间,一个交易品种您只能有一个普通持仓:

    • 如果一个交易品种有一个持仓,同向执行一个交易会提高该持仓的交易量。
    • 如果反向执行交易,那么现有的交易量可能减少,持仓可能会被关闭 (成交交易量等于持仓交易量时) 或撤销 (如果反向成交的交易量大于当前持仓)。


    这没关系,导致反向交易的是 — 已执行的市场订单或触发的挂单。

    下面示例显示了执行两个每笔0.5手的EURUSD买入交易:


    执行这两个交易即是1手的一个普通持仓。

    锁仓系统
    通过这个系统,您可以一个交易品种拥有多个持仓,包括反向持仓。

    如果您有一个交易品种的持仓,执行一个新交易(或触发挂单),那么会另外建立一个新持仓。您当前持仓不会改变。

    下面示例显示了执行两个每笔0.5手的EURUSD买入交易:


    执行这些交易则会新建两个独立的持仓。

    新交易操作类型 - Close By
    新的交易类型已经被加入锁仓账户 — 通过反向持仓来平仓。这个操作允许在单一交易品种关闭两个反向的持仓。如果反向持仓手数不同,那么两个持仓中只有一个订单保留持仓。其交易量将等于平仓手数的差异值,而持仓方向和开盘价将匹配平仓的更大(交易量)。

    相比单独关闭两个持仓,关闭反向持仓允许交易者保留一个点差:

    • 单独平仓情况下,交易者必须支付一个点差两次:以低价位(卖价)关闭买入持仓和高价位关闭卖出持仓(买价)。
    • 使用反向持仓时,第二个持仓的开盘价被用于关闭第一个持仓,而第一个持仓的开盘价被用于关闭第二个持仓。


    在后面那种情况下,下单"close by" 订单。平仓信息在该评论指明。一组反向持仓通过两个"out by"交易关闭。关闭两个持仓得到的总利润/亏损只在一个交易中指明。



  2. 新增在实时报价历史测试自动交易和技术指标的能力。

    真实报价的测试和优化尽可能地接近实际情况。代替基于分钟数据生成的报价,现在可以使用交易商积累的真实报价。有许多来自交易商和流动量提供商的报价。

    若要开始测试或优化真实报价,请在策略中选择相应的模式



    报价数据的大小要比分钟数据大。第一次测试期间,下载它可能需要较长的世界。按月下载的报价数据被存储在TKC文件,在 \bases\[trade server name]\ticks\[symbol name]\。

    测试真实报价
    当测试一个真实报价时,一分钟柱内的点差可能改变,因此生成一分钟报价时,使用相应柱固定的点差。

    如果一个交易品种显示市场深度,那么柱形图会严格根据最后执行的交易价格(Last)来构建。否则,tester会根据收盘价首次尝试构建柱形图,如果这些价格不存在,则使用卖价。无论收盘价是否存在,所有报价上都会触发OnTick 事件。

    请注意,即使根据收盘价构建图表,交易操作也会始终根据卖价和买价执行。例如,如果仅使用开盘柱进行交易的EA交易(例如内置移动平均指标)收到了收盘价信号,它以另一个价格执行一个交易(取决于方向的买价或卖价)。如果使用“每一报价”模式,柱形图通过卖价构建,而交易通过卖价和买价执行。买价作为卖价+对应分钟柱固定点差来计算。

    如果交易品种历史有一个无报价数据的分钟柱,tester 在“每一报价”模式下生成报价。这允许测试一定时期内的EA,以防交易商报价数据的不足。如果交易品种历史记录没有分钟柱但是有适当的分钟报价数据,那么这些报价可以忽略。分钟数据被认为更可靠。
    目前,真实报价的测试和优化仅可能在本地和远程代理。支持MQL5 云网络 在不久的将来也会加入。

  3. Added the Chat. 现在,您可以与您的MQL5.community朋友和同事进行交流沟通了。聊天显示了您MQL5 账户的所有个人信息。开始沟通时,可以直接从聊天窗口登录您的账户或通过平台设置登录:工具 -> 选项 -> 社区。




  4. 简化的模拟账户创建对话框,添加创建锁仓账户的能力。您不再需要填写大表格。只需指定基本数据和选择交易参数:账户类型,入金,杠杆和锁仓功能。



  5. 添加自动分配模拟账户以便快速启动。如果平台还没有账户,第一个可用交易服务器上的模拟账户会在启动时分配。成功打开后,账户连接马上建立。

  6. 现在,每个持仓有一个标签 — 一个独一无二的号码。它通常匹配用于持仓的订单标签,除非标签更改为服务器上服务操作的结果,例如,收取重新持仓库存费时。程序端更新后,标签被自动分配到所有可用持仓。




  7. 修正建立导致持仓反转的市场订单时设置的止损和获利水平。直到目前,没有适当的水平设置给新持仓。
  8. 修正单击交易面板上显示4位及更多小数位的价格。
  9. 修正打印预览窗口的新闻显示。
  10. 修正报价图表显示。
  11. 修正程序端紧急关闭后打开市场深度。
  12. 添加如果显示单击交易面板控制元素时允许市场订单的检查。
  13. 假设大量新建订单和持仓情况下,优化利润和预付款计算。
  14. 添加用户界面的马来语翻译。
  15. 全修改后的用户手册。新设计,交互式屏幕截图和嵌入式视频 — 以最大的方便性了解MetaTrader 5的交易:




MQL5

  1. 添加支持抽象类和纯虚函数。

    抽象类用于创建通用实体,这就是您期待用于创建更具体的派生类。抽象类仅能用作一些其他类的基本类,这就是不能创建抽象类类型对象的原因。

    至少包含一个纯虚拟函数的类是抽象类。因此,从抽象类派生出来的类必须实施其所有纯虚拟函数,否则它们也将是抽象类。

    虚拟函数通过使用pure-specifier语法声明为"pure"。考虑CAnimal类的示例,它的创建只能提供常用功能 – CAnimal类型的对象对于实际使用太普通。因此,CAnimal 是一个很好的抽象类示例:
    class CAnimal
      {
    public:
                          CAnimal();     // 构造函数
       virtual void       Sound() = 0;   // 纯虚拟函数
    private:
       double             m_legs_count;  // 动物腿的数量
      };
    这里Sound() 是一个纯虚拟函数,因为它声明为纯虚拟函数PURE (=0)的说明符。

    纯虚拟函数只是为设置PURE说明符的虚拟函数:(=NULL) 或(=0)。抽象类声明和使用的示例:
    class CAnimal
      {
    public:
       virtual void       Sound()=NULL;   // PURE 类函数,应被覆盖在派生类中,CAnimal 现在是抽象类,不能创建
      };
    //--- 抽象类的后裔
    class CCat : public CAnimal
     {
    public:
      virtual void        Sound() { Print("Myau"); } // PURE被覆盖,CCat 不是抽象类,可以创建
     };
    
    //--- 错误使用的例子
    new CAnimal;         // 'CAnimal' 错误 - 编译器返回"不能实例化抽象类"的错误
    CAnimal some_animal; // 'CAnimal' 错误 - 编译器返回"不能实例化抽象类"的错误
    
    //--- 正确使用的示例
    new CCat;  // 没有错误 - CCat 类不是抽象类
    CCat cat;  // 没有错误 - CCat 类不是抽象类
    抽象类的限制
    如果抽象类的构造函数调用一个纯虚拟函数(直接或间接),结果是未定义的。
    //+------------------------------------------------------------------+
    //| 抽象基类                                           |
    //+------------------------------------------------------------------+
    class CAnimal
      {
    public:
       //--- 纯虚拟函数
       virtual void      Sound(void)=NULL;
       //--- 函数
       void              CallSound(void) { Sound(); }
       //--- 构造函数
       CAnimal()
        {
         //--- 虚拟类函数的显式调用
         Sound();
         //--- 隐式调用(使用第三个函数)
         CallSound();
         //--- 构造函数或析构函数始终调用自己的函数,
         //--- 即使它们是虚拟函数并且已经被派生类中已调用的函数所覆盖
         //--- 如果调用的函数是纯虚拟函数
         //--- 调用会引起“纯虚拟函数调用”的关键的执行错误
        }
      };
    然而,抽象类的构造函数和析构函数可以调用其他成员函数。

  2. 添加支持函数指针来简化事件模式的安排。

    若要声明一个函数指针,请指定"函数指针"类型,例如:
    typedef int (*TFunc)(int,int);
    现在,TFunc是一种类型,可以声明函数的变量指针:
    TFunc func_ptr;
    func_ptr 变量可以存储函数地址以便稍后声明:
    int sub(int x,int y) { return(x-y); }
    int add(int x,int y) { return(x+y); }
    int neg(int x)       { return(~x);  }
    
    func_ptr=sub;
    Print(func_ptr(10,5));
    
    func_ptr=add;
    Print(func_ptr(10,5));
    
    func_ptr=neg;           // 错误:neg 不是 int (int,int) 型
    Print(func_ptr(10));    // 错误:应该有两个参数
    函数指针可以被存储并作为参数传递。您不能得到非静态类函数的指针。

  3. MqlTradeRequest 有两个新字段:

    • position — 持仓标签。锁仓模式交易下为了明确识别而改变和关闭持仓时来填写。在净额系统,填写字段不会有任何影响,因为持仓只识别一个交易品种名称。
    • position_by — 反向持仓标签。它用于通过反向持仓平仓时(打开一个同名但反向的交易品种)。该标签仅用于锁仓系统。

  4. 添加TRADE_ACTION_CLOSE_BY 值到 ENUM_TRADE_REQUEST_ACTIONS 交易操作类型枚举 — 通过反向持仓。该标签仅用于锁仓系统。

  5. 添加交易操作标签到适当订单,交易和持仓属性的枚举:

    • 添加ORDER_TICKET 属性到 ENUM_ORDER_PROPERTY_INTEGER — 订单标签。每个订单会分配一个独一无二的号码。
    • 添加 DEAL_TICKET 属性到 ENUM_DEAL_PROPERTY_INTEGER — 交易标签。每笔交易会分配一个独一无二的号码。
    • 添加POSITION_TICKET 属性到 ENUM_POSITION_PROPERTY_INTEGER — 持仓标签。每个新持仓会分配一个独一无二的号码。它通常匹配用于持仓的订单标签,除非标签更改为服务器上服务操作的结果,例如,收取重新持仓库存费时。若要找出一个用于持仓的订单,请应用POSITION_IDENTIFIER 属性。POSITION_TICKET 值对应MqlTradeRequest::position。

  6. 添加ORDER_TYPE_CLOSE_BY 值到he ENUM_ORDER_TYPE 订单类型枚举 — close by 订单。
  7. 添加ORDER_POSITION_BY_ID 值到ENUM_ORDER_PROPERTY_INTEGER 订单属性枚举 —ORDER_TYPE_CLOSE_BY 类型订单的反向持仓标识符。
  8. 添加DEAL_ENTRY_OUT_BY 值到 ENUM_DEAL_ENTRY 交易方向枚举 — 由close by操作执行交易。
  9. MqlTradeTransaction 也有两个类似的字段:

    • position — 由交易活动影响的持仓标签。这里填写处理市场订单(TRADE_TRANSACTION_ORDER_* except TRADE_TRANSACTION_ORDER_ADD,在这里持仓标签尚未分配) 和订单历史(TRADE_TRANSACTION_HISTORY_*)相关的交易活动。
    • position_by — 反向持仓标签。它用于通过反向持仓平仓时(打开一个同名但反向的交易品种)。这里只填写通过反向持仓而平仓的订单 (close by) 和通过反向持仓而关闭的交易 (out by)。

  10. 添加PositionGetTicket函数 — 根据持仓列表的索引返回一个持仓标签和使用PositionGetDouble, PositionGetInteger 和PositionGetString函数自动选择持仓用于进一步工作。
    ulong  PositionGetTicket(
       int  index      // 持仓列表索引
       );

  11. 添加PositionSelectByTicket 函数 — 通过指定标签为进一步工作选择一个持仓。
    bool  PositionSelectByTicket(
       ulong   ticket     // 持仓标签
       );

  12. 添加SYMBOL_MARGIN_HEDGED 值到 ENUM_SYMBOL_INFO_DOUBLE 交易品种属性枚举 — 合约大小或一手锁仓预付款(一个交易品种的反向持仓)。

    • 如果一个交易品种指定了初始预付款 (SYMBOL_MARGIN_INITIAL),锁仓预付款被指定为绝对值(以货币计算)。
    • 如果没有设置初始预付款(等于0),预付款计算中将被使用的合约大小在SYMBOL_MARGIN_HEDGED指定。预付款使用对应一个交易品种类型 (SYMBOL_TRADE_CALC_MODE)的等式计算。

    锁仓预付款计算的详细信息会在MetaTrader 5 交易平台帮助中说明。

  13. 添加ACCOUNT_MARGIN_MODE 值到 ENUM_ACCOUNT_INFO_INTEGER 账户属性枚举 — 当前交易账户的预付款计算模式:

    • ACCOUNT_MARGIN_MODE_RETAIL_NETTING — 用于净额模式账户持仓时的场外交易市场(一个交易品种一个持仓)。预付款计算基于交易品种类型 (SYMBOL_TRADE_CALC_MODE)。
    • ACCOUNT_MARGIN_MODE_EXCHANGE — 用于交易所市场。预付款计算基于交易品种设置中指定的折扣。折扣由交易商设置,但是它们不能低于交易所设置的值。
    • ACCOUNT_MARGIN_MODE_RETAIL_HEDGING — 用于独立持仓账户场外交易市场(锁仓,一个单一交易品种可以有多个持仓)。预付款计算基于交易品种类型 (SYMBOL_TRADE_CALC_MODE)。也要考虑锁仓预付款大小 (SYMBOL_MARGIN_HEDGED) 。

  14. 添加TERMINAL_SCREEN_DPI 值到 ENUM_TERMINAL_INFO_INTEGER 客户端属性枚举 — 分辨率显示数据通过每英寸的点数来衡量 (DPI)。该参数的信息允许指定图形对象的大小,这样它们在不同分辨率的显示器上看起来一样。

  15. 添加 TERMINAL_PING_LAST 值到 ENUM_TERMINAL_INFO_INTEGER 客户端属性 — 以微秒计算交易服务器最后得到的ping值。一秒等于一百万微秒。

  16. 修正返回SendFTP函数调用结果之前,成功发送后返回 FALSE 而不是 TRUE。
  17. 修正偶尔导致"违规访问"执行错误的StringConcatenate函数错误。
  18. 修正使用模板函数时发生的几个错误。
  19. 添加为打印,警示和评论功能显示超过4000字符行的能力。
  20. 修正ArrayCompare函数通过不同于开始时期的初始持仓变化来比较数组和函数本身时产生的错误。
  21. 添加支持标准库的锁仓功能:

    CPosition
    添加类函数:

    • SelectByMagic — 根据魔幻数选择持仓和进一步工作的交易品种。
    • SelectByTicket — 通过进一步工作的标签选择持仓。

    CTrade
    添加类函数:

    • RequestPosition — 收到持仓标签。
    • RequestPositionBy — 接收反向持仓标签。
    • PositionCloseBy — 通过反向持仓支持标签平仓。
    • SetMarginMode — 根据当前账户设置来设置预付款计算模式。

    添加重载类函数:

    • PositionClose — 平仓标签。
    • PositionModify — 修改持仓标签。

    CAccountInfo
    改变类函数:

    • MarginMode — 接收预付款计算模式。直至目前,类函数的工作类似于新的StopoutMode 类函数。
    • MarginDescription — 接收预付款计算模式为字符串。直至目前,类函数的工作类似于新的StopoutModeDescription类函数。

    添加类函数:

    • StopoutMode — 接收最小预付款水平规范模式。
    • StopoutModeDescription — 接收最小预付款水平规范模式为字符串。

    CExpert
    添加类函数:

    • SelectPosition — 为进一步工作选择持仓。

  22. 对标准程序库添加一些改进。


信号

  1. 修正几个交易信号窗显示错误。


Tester

  1. 修正几个交易品种类型上妨碍计算手续费的错误。
  2. 修正根据相应持仓的专家字段填写激活SL/TP得到的交易订单的专家字段。之前,不填写这些内容。
  3. 修正切换到通常状态并进一步优化结果的标签。
  4. 修正计算和显示“轨道线”指标。
  5. 优化可视化测试。
  6. 假设大量新建订单和持仓情况下,优化利润和预付款计算。
  7. 优化高频交易期间的交易操作。
  8. 现在,如果是非关键交易品种属性请求(不需要当前报价),则不执行历史同步。例如,SYMBOL_SELECT,SYMBOL_DIGITS,SYMBOL_SPREAD_FLOAT,SYMBOL_TRADE_CALC_MODE,SYMBOL_TRADE_MODE,SYMBOL_TRADE_STOPS_LEVEL,SYMBOL_TRADE_FREEZE_LEVEL,SYMBOL_TRADE_EXEMODE等等。之前,非关键交易品种历史记录在其属性的任何请求下都会同步。

MetaEditor

  1. 修正“全字匹配”模式下文件的搜索词。
  2. 添加在所需文件的编译结果行上双击移动到一个文件。
  3. 修正显示Windows XP中的一些控制元素。


  1. 更新文档。
17 十二月 2015
新版MetaTrader 5 平台 Build 1240:操作更快以及嵌入式视频

主机

  1. 在虚拟主机向导对话框添加了教学视频链接"如何租用虚拟平台" 。请观看这个两分钟视频,学习如何轻松启动自动交易或全天候24小时复制信号。.


    该视频以及许多其他视频都在 MetaQuotes软件公司YouTube 官方频道提供。
  2. 主机:修正从EA交易调用自定义指标或调用自定义指标中的EX5程序库时的主机迁移。.

程序端

  1. 高频交易期间(每秒50及更多操作),加速打开订单和持仓列表的更新。
  2. 大量交易品种(上万种)情况下优化并显著加速一台交易服务器程序端的初始同步。现在,建立连接后您可以更快速的开展工作。
  3. 优化并显著减少程序端的内存消耗。
  4. 关闭/打开程序端时添加保存和恢复市场深度的设置。
  5. 修正拖拽程序端窗口时发生在Windows 10下的构件。
  6. 修正许多命令和对话框的上下文帮助。若要激活有关特定元素的帮助,请将光标移至其上面并按下F1。
  7. 使界面适应高分辨率屏幕(4K)的工作正在进行中。

MQL5

  1. 为负责接收订单和交易数据的OrderGetString,HistoryOrderGetString,和HistoryDealGetString函数添加新属性:

    • ORDER_EXTERNAL_ID - 外部交易系统的订单ID(在交易所)。
    • DEAL_EXTERNAL_ID - 外部交易系统的成交 ID 。

  2. 修正使用架构和类时ZeroMemory 函数的操作。在某些情况下内存清理不执行。
  3. 添加SendFTP 函数操作期间的错误代码。该函数发送文件到选项窗口FTP标签上指定的地址。

    • ERR_FTP_NOSERVER - 设置中不指定FTP服务器
    • ERR_FTP_NOLOGIN - 设置中不指定FTP登录名
    • ERR_FTP_FILE_ERROR - 文件不存在
    • ERR_FTP_CONNECT_FAILED - 连接FTP服务器失败
    • ERR_FTP_CHANGEDIR - FTP服务器未发现文件上传目录
    • ERR_FTP_CLOSED - FTP服务器连接关闭

  4. 修正子类对象和其父类之间通过继承方式的类型转换访问。
  5. 修正类模板中的几处错误。
  6. 修正使用CopyTicks函数的请求报价。当为连续相同交易报价指定COPY_TICKS_TRADE 参数(仅复制交易报价)时,只有第一个报价会通过。
  7. 修正定制类型变量大小的定义。
  8. 修正在CryptDecode函数中使用ZLib时导致无限解压缩循环的错误。

Tester

  1. 修正与主测试交易品种不同的交易品种的历史价格同步。
  2. 修正OnTrade交易事件处理程序中加倍TRADE_TRANSACTION_DEAL_ADD 交易(添加交易到历史记录)。
  3. 更改了遗传优化期间的测试行为。现在,所有遗传优化后获得的独特结果都参与传递。之前,只有1/4的结果可以使用。.

MetaEditor

  1. 添加教学视频"如何在MQL5向导中创建自动交易"的链接到MQL5向导。请观看该三分钟视频,开发自动交易,无需编写单行代码。


    该视频以及许多其他视频都在 MetaQuotes软件公司YouTube 官方频道提供。
  2. 修正其中一个窗口完全展开时的窗口排列命令。窗口菜单允许您平铺,垂直,水平和层叠排列打开的文件。
  3. 使界面适应高分辨率屏幕(4K)的工作正在进行中。
更新文档。
30 十月 2015
新的MetaTrader 5 Build 1210:增强市场深度和常规改进

程序端

  1. 添加以低于市场深度市场价的价格下限价订单的功能。这允许您在市场以指定价格获得一个订单执行保证。

    如果我们通过买家/卖价界限拖拽限价订单,它将变成止损订单(买入限价将被买入止损替代,而卖出限价-变为卖出止损)。按住Crtl 拖拽,可以使限价订单不被替换为止损订单。




  2. 在图表设置添加“显示快速交易按键”。这可以使您从图表隐藏一键交易面板启用按键和市场深度。




  3. 修正提示工具和其他应用之间偶尔出现的冲突。

MQL5

  1. 修正以AS_SERIES标识的动态数组复制历史数据时Copy*函数的操作。标识通过ArraySetAsSeries函数设置,表明以时间序列执行数组元素的指数化。
  2. 更改通过ChartSetInteger和ChartGetInteger管理的CHART_SHOW_ONE_CLICK 属性。之前,该属性允许在图表上显示/隐藏一键交易面板。现在,它也显示/隐藏图表上设置一键交易面板和市场深度的按键(类似图表设置中的“显示快速交易 按键”“)。
  3. 修正模板操作。
更新文档。

23 十月 2015
MetaTrader 5平台更新 Build 1200:接收报价历史和直接支付服务

程序端

  1. 在市场报价新增使用报价历史的功能。之前,操作期间报价图表只显示程序端收集的历史。现在,在交易服务器上您就可以访问整个报价历史。禁用自动滚 动,使用鼠标适时开始回滚报价图表,以常见价格图表相同的方式从交易服务器下载缺失的历史。新功能将有助于想要获得最详细价格图表的交易者。



    使用CopyTicks() 函数接收更深层次的报价历史。如果后者在交易服务器上,那么它已得到修改以便于它可以请求缺失的历史并下载它。

  2. 新增一个快速打开/关闭市场深度的图标。该图标位于图表上的一键交易面板的附近。您也可以使用新的热键Alt+B。热键也用于市场报价窗口,可以打开市场报价中突出显示的交易品种的市场深度。




  3. PC硬件特点和操作系统的信息现在从客户端开始就已经记录在日志中。例如:
    2015.10.14 14:48:18.486	Data Folder: C:\Program Files\MetaTrader 5
    2015.10.14 14:48:18.486	Windows 7 Professional (x64 based PC), IE 11.00, UAC, 8 x Intel Core i7  920 @ 2.67GHz, RAM: 8116 / 12277 Mb, HDD: 534262 / 753865 Mb, GMT+03:00
    2015.10.14 14:48:18.486	MetaTrader 5 build 1190 started (MetaQuotes Software Corp.)
  4. 改进市场报价中交易品种的工作。

    • 添加市场报价中交易品种显示的数量和交易服务器上可用的交易品种总数。
    • 通过智能选择列表添加一行以便添加新交易品种。
    • 新交易品种行的搜索不仅可以通过交易品种名称执行,还可以通过其描述和国际名称完成。




  5. 添加支持不同语言的经济日历。
  6. 添加经济日历缺失的国家图标。
  7. 添加在市场报价打开交易品种管理窗口的热键 - Ctrl+U。
  8. 修正根据窗口菜单命令安排打开图表窗口。
  9. 修正使用强化认证时偶尔阻碍程序端查找证书文件的错误。
  10. 修正有时可能导致价格历史同步循环的错误。
  11. 如果交易品种在请求执行模式下进行交易,修正了交易量增加后之前持仓的无效止损/止盈水平。
  12. 如果交易品种的买入持仓在市场深度的“只买入”交易模式,修正了下卖单的检查功能。
  13. 修正追踪止损功能的操作。在一些罕见的情况下,持仓的保护性止损的不正确移动。
  14. 程序端界面进一步适用于高分辨率的屏幕(4K)。
  15. 修正卸载尽管MQL5程序定期要求却还是过多的历史数据。
  16. 修正在Windows10下工作时一些用户界面的显示问题。
  17. 更新用户界面的翻译。

市场

  1. 已修改并优化MQL5市场中产品数据库的操作。
  2. VPS上已经禁止程序端无MQL5.community账户的购买。现在购买需要在程序端设置中指定MQL5.community账户:工具-选项-社区。
  3. 添加使用银联直接购买产品。
  4. 增强在MQL5市场购买产品时的日志内容。


主机和信号

  1. 支付虚拟主机和信号订阅现在可以直接从付款系统转账。

    若要支付主机服务,用户无需登录MQL5.community账户充值。 为服务付款现在可以使用一种可用的付款系统从平台直接转账。



    选择一种可用的系统,进行网上转账:




    同样,为交易信号订阅付款也可以通过付款系统从程序端直接完成。




    所需金额将首先转到您的MQL5.community 账户,从这里完成为服务付款。因此,您可以拥有一个明确统一的租赁虚拟主机平台和信号订阅的历史并可以轻松访问和审查您MQL5.community 服务的全部付款。
  2. 添加在32位客户端工作时管理虚拟主机(迁移除外)。
  3. 修正迁移FTP出口设置到虚拟主机,尽管允许通过FTP发布报告。

MQL5

  1. 启用新优化的编译器。在64位平台上的程序执行速度提升了5倍。MQL5程序在最近的MetaEditor版本中应该重新编译。
  2. 扩展的MqlTick 结构格式。现在,通过了以毫秒为单位的报价到达时间,以及决定哪个报价参数已被更改的标识。
    struct MqlTick
      {
       datetime     time;          // 最近更新价格的时间
       double       bid;           // 当前卖价
       double       ask;           // 当前买价
       double       last;          // 当前收盘价
       ulong        volume;        // 当前收盘价的交易量
       long         time_msc;      // 以毫秒为单位的最近更新价格的时间
       uint         flags;         // 报价标识
      };
    无论与之前报价相比是否有变化都会填充每个报价参数。因此,可以找出过去任何时刻的正确价格,无需在报价历史搜索之前的值。例如,即使报价到达期间只有卖价变化,该结构仍然包含其他参数,包括之前的买价,交易量等等。您可以分析报价标识,找出具体更改了哪个数据:

    • TICK_FLAG_BID - 更改卖价
    • TICK_FLAG_ASK  - 更改买价
    • TICK_FLAG_LAST - 更改最终成交价
    • TICK_FLAG_VOLUME - 更改交易量
    • TICK_FLAG_BUY - 报价是买入交易结果
    • TICK_FLAG_SELL - 报价是卖出交易结果

    MqlTick 结构通过两种类函数使用:

    • CopyTicks - 该类函数不支持旧的结构格式。当调用CopyTicks函数时,之前使用旧的报价格式编译的EX5函数将返回错误4006 (ERR_MQL_INVALID_ARRAY)。
    • SymbolInfoTick - 该类函数同时支持新旧两种结构格式。

  3. 添加允许您创建类似C++中的参数化类的类模板。那甚至可以使其更加抽象并且能够以统一的方式使用相同的代码处理不同类的对象。使用示例:
    //+------------------------------------------------------------------+
    //|                                                    TemplTest.mq5 |
    //|                        Copyright 2015, MetaQuotes Software Corp. |
    //|                                             https://www.mql5.com |
    //+------------------------------------------------------------------+
    #property copyright "Copyright 2015, MetaQuotes Software Corp."
    #property link      "https://www.mql5.com"
    #property version   "1.00"
    //+------------------------------------------------------------------+
    //| 声明一个模板类                                                     |
    //+------------------------------------------------------------------+
    template<typename T>
    class TArray
      {
    protected:
       T                 m_data[];
    
    public:
    
       bool              Append(T item)
         {
          int new_size=ArraySize(m_data)+1;
          int reserve =(new_size/2+15)&~15;
          //---
          if(ArrayResize(m_data,new_size,reserve)!=new_size)
             return(false);
          //---
          m_data[new_size-1]=item;
          return(true);
         }
       T                 operator[](int index)
         {
          static T invalid_index;
          //---
          if(index<0 || index>=ArraySize(m_data))
             return(invalid_index);
          //---
          return(m_data[index]);
         }   
      };
    //+------------------------------------------------------------------+
    //| 指针数组的模板类析构函数,删除                                       |
    //| 对象,数组中存储指针的对象。                                         |
    //|                                                                  |
    //| 请注意继承TArray 模板类                                            |
    //+------------------------------------------------------------------+
    template<typename T>
    class TArrayPtr : public TArray<T *>
      {
    public:
       void             ~TArrayPtr()
         {
          for(int n=0,count=ArraySize(m_data);n<count;n++)
             if(CheckPointer(m_data[n])==POINTER_DYNAMIC)
                delete m_data[n];
         }
      };
    //+--------------------------------------------------------------------------+
    //| 声明类。对象指针将存储在数组中                                               |
    //+--------------------------------------------------------------------------+
    class CFoo
      {
       int               m_x;
    public:
                         CFoo(int x):m_x(x) { }
       int               X(void) const { return(m_x); }
      };
    //+------------------------------------------------------------------+
    //|                                                                  |
    //+------------------------------------------------------------------+
    TArray<int>     ExtIntArray;   // 例如 TArray (int 类型 的特定TArray )
    TArray<double>  ExtDblArray;   // 例如TArray (double类型的特定 TArray )
    TArrayPtr<CFoo> ExtPtrArray;   // 例如 TArrayPtr (CFoo类型的特定 TArrayPtr )
    //+------------------------------------------------------------------+
    //| 脚本程序起始函数                                                   |
    //+------------------------------------------------------------------+
    void OnStart()
      {
    //--- 用数据填充数组
       for(int i=0;i<10;i++)
         {
          int integer=i+10;
          ExtIntArray.Append(integer);
          
          double dbl=i+20.0;
          ExtDblArray.Append(dbl);
          
          CFoo *ptr=new CFoo(i+30);
          ExtPtrArray.Append(ptr);
         }
    //--- 输出数组内容
       string str="Int:";
       for(int i=0;i<10;i++)
          str+=" "+(string)ExtIntArray[i];      
       Print(str);   
       str="Dbl:";
       for(int i=0;i<10;i++)
          str+=" "+DoubleToString(ExtDblArray[i],1);
       Print(str);   
       str="Ptr:";
       for(int i=0;i<10;i++)
          str+=" "+(string)ExtPtrArray[i].X();      
       Print(str);
    //--- 通过new创建的CFoo对象不应删除,因为它们在TArrayPtr<CFoo>对象的析构函数被删除  
      }
    执行结果:
    TemplTest (EURUSD,H1)    Int: 10 11 12 13 14 15 16 17 18 19
    TemplTest (EURUSD,H1)    Dbl: 20.0 21.0 22.0 23.0 24.0 25.0 26.0 27.0 28.0 29.0
    TemplTest (EURUSD,H1)    Ptr: 30 31 32 33 34 35 36 37 38 39

  4. 新操作 * 和 & 通过引用接收变量和接收引用变量。
  5. 添加ObjectsDeleteAll 函数的重载形式 - 通过图表子窗口的名称前缀删除指定类型的全部对象。
    int  ObjectsDeleteAll(
       long           chart_id,   // 图表ID
       const string     prefix,   // 对象名称前缀
       int       sub_window=-1,   // 窗口指数
       int      object_type=-1    // 删除的对象类型
       );

  6. 修正ObjectGetValueByTime 函数操作。之前,有时可能会返回错误的图表时间价格值(例如,水平趋势线)。
  7. 修正服务器上缺乏历史数据时的Copy*函数的操作。 之前,这种情况在返回控制之前会导致30-50秒的延迟。
  8. 为MQL5标准程序库添加了一些改进。
  9. 标准程序库 文档翻译为德语,法语,中文,土耳其语,西班牙语和葡萄牙语。
  10. 添加了日语MQL5 文档

Tester

  1. 选择在策略测试中运行的程序的过程变得更加容易。 现在根据存储EA交易和指标的目录,以树状显示列表。




  2. 显示客户端线型可视化测试期间的一些指标。
  3. 修正了通过策略测试调试MQL5程序时设置杠杆和图表时间表。
  4. 修正历史记录测试时调试指标。
修正崩溃日志中报告的错误。

更新文档。


3 六月 2015
MetaTrader 5 build 622: 更简单快速地从市场购买自动交易

现在,您可以无需注册即可从您的MetaTrader 4/5 程序端直接一步购买任何市场 应用程序。只需点击购买和选择首选支付方式。


然后,您将被重新定向到支付系统的网页,完成购买。PayPal,WebMoney,Neteller 或银行卡 - 您可以选择从现有自动交易和指标商店购买产品的支付方式。


购买之后,我们仍然建议您注册一个MQL5.community账户,以便您的产品可以自动连接到您的账户。MQL5账户可以帮您更新产品并在多台电脑上安装它。此外,MQL5.community 账户还可以使您有机会访问MetaTrader平台的大量的其他服务, 例如复制成功交易者交易的 交易信号,可以连续操作应用程序的虚拟主机 和从开发者订购独一无二自动交易的自由职业者服务

现在,您应该了解了获得自动交易的最快最轻松的方法。5 000多种MetaTrader 应用程序已做好准备,在市场中等待着您 - 只需 选择和购买


22 五月 2015
MetaTrader 5 平台更新 Build 1150:轻松地市场购买,历史交易记录和交易时间&交易销售的调试

市场

  1. 我们引进了"直接" 购买的新机制。现在从市场购买自动交易或指标更加容易,并且您甚至无需MQL5.community账户。

    一步购买
    用户无需登录MQL5.community 账户,向里面充值。现在可以使用平台提供的支付系统直接从平台购买支付产品。为了保持市场购买历史记录的清楚性和统一性,所需的支付额将首先转到您的MQL5.community账户,在那里完成产品的支付。

    您可以轻松地从您MQL5.community 个人档案访问和查看您的所有支付记录。





    购买无需注册
    没有MQL5.community账户也可以在市场购买产品。点击"购买" 并使用提供的支付系统为产品付款。



    然后您将回到到支付系统网页,完成购买。



    在那之后,我们强烈建议您注册一个MQL5.community账户,您的购买将会自动关联到账户。这能够使您可以在多个计算机更新和安装产品。

编辑器

  1. 新功能允许在历史价格调试EA和技术指标。在旧版中,调试需要实时图表。

    现在,在所需的历史数据可以测试任何程序。调试是在策略测试的可视化测试模式中运行。应用程序在tester的模拟序列报价图表上执行。

    在MetaEditor设置中配置调试参数:交易品种,时间表,间隔,执行模式,报价生成模式,初始入金和杠杆。这些参数将被应用于可视化测试。



    在代码中设置断点,然后使用历史价格开始调试。



    这将启动可视化测试和调试过程。



主机

  1. 虚拟主机服务中已经实现了多个改进和修复。

    主要变化是在运行Linux和Mac OS的计算机上操作 Wine。在Wine中所有功能都可用于所有分配的虚拟服务器,包括移动,监控性能和查看日志。


    日志操作也已经变化。如果用户请求记录太多,那么只有特定时期的部分开始日志可被下载。这会防止因日志数量过大而导致的性能退化。如果您想要进一步下载日志,您不再需要更改请求日期。只需在日志查看器窗口选择最后一排并按下PgDn。.




程序端

  1. 添加支持一种特殊类型的非交易资产,它可以作为客户资产,为其他交易工具所有的持仓提供所需的预付款。例如,在一个交易者的账户中有一定数量的黄金实物 ,它可以用作持仓预付款(担保)。

    诸如此类的资产都显示为持仓。它们的值通过以下公式计算:合约大小 * 手数 * 市场价格 * 流动性比率。

    这里,流动性比率意味着交易商允许用于预付款的资产比率。


    资产被添加至客户净值并提高了可用预付款,从而增加了允许账户操作的交易量。

    因此,现在可以开通多种预付款类型的账户。


    在上面示例中,交易者拥有1盎司黄金,当前市值1 210.56USD。该值被加入净值并且在零结余情况下可用预付款允许交易者继续交易。

  2. 新的点图表市场深度和交易时间&销售数据。

    拥有实际交易价格的交易工具报价图表现在显示在市场深度。交易上进行的所有事务都绘制在这个图表上:
    • 红圈 - 卖出交易
    • 蓝圈 - 买入交易
    • 绿圈 - 交易方向未定义。它用于交易无法传输交易方向的时候。在这种情况下,交易方向基于相较于卖价买价的交易价格来决定。买入交易就是在买价或更高价格下执行,卖出交易在卖价或更低价格执行。如果交易价格在卖价和买价之间,则不定义方向

    圆圈越大,交易量越大。交易量在订单号图表下也显示为直方图。



    在直方图的上部和下部,会显示当前买卖提供的总交易量。

  3. 交易品种选择对话框现在包含显示交易品种到期日期的列。以及,从列表可以隐藏到期工具。到期合约自动替换为活动合约。



    所有到期交易品种都被隐藏以保持更紧凑的显示。这在期货市场的工作中会尤其有用。无关交易品种是通过"最后交易"参数定义的到期交易品种。这个日期在"到期"列中指明。若要查看所有交易品种,请点击"显示到期合约"。
    为了更便于显示,交易品种列表会自动分类:

    • 首先列出来的是没有到期日期的交易品种
    • 紧接着是始于最近日期到期的交易品种
    • 然后显示始于去年到期的过期交易品种
    • 按照字母顺序排列的其他交易品种

    快捷菜单中的选项"自动移除到期交易品种"允许以"市场报价"窗口的活动交易品种替代过期交易品种。



    程序端重启后,过期交易品种被隐藏,活动交易品种替代添加。例如,LKOH3.15的到期期货合约将被接下来的定义相同的资产LKOH6.15合约所替代。

    如果没有EA交易运行,那么相应打开图表中的交易品种也会被替代。

  4. 修正更新市场深度窗口中的交易按钮取决于是否有持仓,以及仅持有买入持仓的权限。如果没有持仓,那么关闭按钮无法使用。如果不允许卖出持仓,那么卖出按钮无法使用。
  5. 程序端界面进一步适应高分辨率屏幕(4K)。
  6. 修正请求执行模式下验证关闭持仓交易量,防止交易量少于最小允许值。
  7. 修正可能导致从一个目录启动多个程序端实例的错误。
  8. 新增以不同语言支持和自动过滤经济日历。依据程序端界面语言执行过滤。
  9. 日志查看器现在具有通过当前显示的日志进行搜索的功能。



    它搜索日志显示列表中的单词/词组。
  10. 添加泰语的客户端翻译。
  11. 更新北印度语的客户端翻译。

MQL5

  1. 新函数GetMicrosecondCount 返回自从MQL5程序启动后通过的微秒数:
    ulong  GetMicrosecondCount();
    该函数可以用于配置程序和确定"bottlenecks"。

  2. ENUM_OPENCL_PROPERTY_INTEGER枚举中的新图表属性CL_BUFFER_SIZE - 它以字节返回OpenCL buffer实际大小。该属性可以通过CLGetInfoInteger函数接收。
  3. WebRequest 函数的错误通知已经更改。如果错误发生,'result' 数组将包含错误描述。
  4. ArraySort,ArrayBsearch,ArrayMinimum 和 ArrayMaximum 分类和搜索功能现在可以使用多维数组。分类和搜索只能通过第一个(0)数组指数来执行。之前,这些功能只能在一维数组下使用。
  5. 修正宏编译的一些漏洞。

Tester

  1. 可视化测试操作中的一些改进和漏洞修复。测试器现在通过工具条提供更顺畅的测试速度控制。

修正崩溃日志中报告的错误

  1. 更新的文档。

将通过LiveUpdate系统提供更新。

20 三月 2015
MetaTrader 5 Platform Update Build 1100: Faster Testing and Optimization of Expert Advisors

Tester

  1. A status of connection to MQL5 Cloud Network is now displayed in the Agents Manager. This allows users to easily check if they can receive tasks from the cloud computing network after they install agents.


    A status of connection to MQL5 Cloud Network


  2. Some improvements and bug fixes have been made in the operation of the Strategy Tester. Time spent on intermediate preparatory operations and network latency has been significantly reduced. Testing and optimization are now faster in all operating modes: working with local testing agents, with a farm of agents in the local network and using MQL5 Cloud Network.

Trading Terminal

  1. Added display of the number of unread emails in the "Mailbox" tab of the Toolbox window.


    Added display of the number of unread emails


  2. The Navigator window now contains the list of Expert Advisors running on the active trading account. In addition to the Expert Advisor name, a chart on which the EA is running is specified in the list. An icon indicates whether the EA is allowed to trade.


    The Navigator window now contains the list of Expert Advisors running on the active trading account


    The context menu contains commands for enabling or disabling automated trading for any of the Expert Advisors, as well as for viewing its properties or removing it from the chart.
  3. Improved accuracy of the algorithm for determining access points available for connection to a trading server.
  4. Fixed an error that could occasionally clean the database of client accounts when a terminal was reinstalled over an existing one.
  5. The terminal interface has been further adapted for high resolution screens (4K).

Market

  1. Fixed updating of the MQL5 account balance after purchasing or renting a product.

Virtual Hosting

  1. Fixed migration of custom indicators to the virtual hosting environment.
  2. Fixed updating of the virtual hosting status in the Navigator window.

MQL5

  1. Fixed errors which could occasionally interfere with the optimization of Expert Advisors in MQL5 Cloud Network.
  2. Fixed call of OnDeinit when deleting an Expert Advisor using the ExpertRemove function during testing. Previously, under the conditions described the OnDeinit event was not called.
  3. Fixed errors in use of resources in EX5 libraries.
  4. Fixed errors in the analysis of macros.

Fixed errors reported in crash logs.

Updated documentation.

The update is available through the LiveUpdate system.

16 二月 2015
MetaTrader 5 平台在 Build 1085 中的更新

MetaTrader 5 客户终端 build 1085
  1. 终端: 现在可以使用新的虚拟主机服务,可以在客户终端中位一个交易账户直接租用一个虚拟服务器,它提供了对交易服务器稳定的连接以及用于在EA进行的不间断的计算操作,交易复制现在也变得更加简单了。

    虚拟服务器是由 MetaQuotes 软件公司的伙伴公司维护的。
    分配一个虚拟服务器
    为了在虚拟服务器上取得虚拟终端,请使用所需的交易账户连接并通过上下文菜单中的"注册一个虚拟服务器"命令来执行。




    虚拟主机向导窗口出现,它展示了虚拟主机网络是如何工作的。获得一个虚拟服务器的过程包括三个步骤:首先, 您将了解到如何准备迁移;在那之后,您将可以选择距离经纪商交易服务器最近的虚拟服务器,以最小化网络延迟;



    您可以选择提供给每个MQL5.community注册用户的免费一天主机服务,或者选择一种提供的服务计划;最后,您将可以根据您的目标来选择数据迁移的模式:

    • 如果您需要同时运行EA交易/指标和复制交易,就需要完整迁移;
    • 如果不需要订阅信号,则只有EA交易和指标;
    • 只有交易的复制 - 只有信号复制设置(没有图表或者程序)被迁移。

    在选择了迁移模式之后,您可以通过点击“现在迁移”来立即运行虚拟服务器,或者晚些在任何时候这样做。

    准备迁移
    在运行虚拟终端之前,您应当为它准备一个活动的环境 - 图表,载入的指标和EA交易,信号复制参数和终端设置。

    • 图表和市场报价 - 从市场报价中隐藏所有不需要的资产以减少流量。关闭不需要的图表。在终端设置中,指定"窗口中的最大柱数"所需的值 - 终端在那之后会重新启动。
    • 指标和EA交易 - 把所需的EA和指标附加到图表上。在市场上购买的以及在图表上载入的产品也会被迁移,它们会保留完整功能,并且可用的激活数不会减少。所有指标和EA交易的外部参数应当正确设置。
    • 电子邮件, FTP 和信号 - 如果 EA 交易要发送电子邮件,通过 FTP 上传数据或者复制信号的交易,要确保指定了所有所需设置。在社区页面正确设置您MQL5.community账户的登录名和密码,这对信号复制是必需的。
    • 交易和复制信号的许可 - 在虚拟终端中永远允许自动化交易,为了操作信号,要在信号部分设置复制的参数。
    • WebRequest - 如果在虚拟终端中运行的程序使用WebReqest()函数来发送 HTTP 请求, 您应当设置许可并且在EA交易页面列出所有信任的URL。


    迁移
    迁移就是把当前活动的环境从客户终端中传输到虚拟终端中,
    迁移是在每次客户终端的同步中进行的。同步永远是单方向的过程 - 客户终端的环境被转移到虚拟终端中,而永远不会反过来。虚拟终端的状态可以通过请求终端来监控,还有EA交易的记录以及虚拟服务器的监控数据。
    为了进行同步,要打开账户的上下文菜单并选择迁移类型。




    这样,您就一直都能改变图表的数量和交易品种列表,运行的程序和它们的输入参数,终端设置和信号的订阅等等。

    当进行迁移时,所有的数据都记录在客户终端的记录中。


    在同步之后,打开虚拟终端的主日志可以检查其中执行的操作。




    操作虚拟终端
    租用的虚拟服务器状态也可以客户终端中很容易地监控,在上下文菜单中执行 "详细" 命令。



    信息在四个页面中作展示:

    • 详细 - 虚拟服务器本身的数据以及终端的活动环境。
    • CPU 使用 - CPU 使用图表, %.
    • 内存使用 - 内存使用图表, Mb.
    • 硬盘使用 - 硬盘使用图表, Mb.
    如需了解有关该服务的更多信息,请阅读文章"如何准备迁移到虚拟主机上的交易账户""虚拟主机服务的使用规则"

  2. 市场: 现在, 可以租用MetaTrader 市场中的产品了,租期为1,3,6或者12个月。这对开发人员和买家来说都是很有利的,作者可以通过允许潜在买家以较低花费检验他们的产品而极大地增强用户的信心,对于买家来说,租用也是在买入产品之前对它进行评估的另一种方法。和试用版不同,租用的产品除了有效的使用期限之外没有任何限制。
    任何市场产品的开发人员都可以选择他们的产品是否可以租用以及设置租用的价格。




    开发人员也可以选择不出租他们的产品,而只是在完整版中提供没有限制的使用。
    如果产品可以租用,它的网页上显示的可能选项是: 租用时间和价格。点击租用并选择租用的时间,



    在租期过期之后,用户可以续租或者购买完整版。

  3. 终端: 删除了在终端中使用“另存为图片”命令或者通过MQL5的Screenshot()函数保存图表截图中的 "MetaTrader 5, @ 2001-2015 MetaQuotes-Software Corp."版权信息,这使得屏幕截图的发布更为简单。




  4. 终端: 修正了内建的 Gator 振荡技术指标的计算和参数的管理。
  5. 终端: 提高了连接到交易服务器时对连接点的扫描。
  6. 终端: 修正了偶然发生的 LiveUpdate 运行错误。
  7. MQL5: 增加了 SIGNAL_BASE_CURRENCY 信号属性 - 信号提供商的存款币别 - 加到 ENUM_SIGNAL_BASE_STRING 枚举中。该属性可以通过 SignalBaseGetString 函数来读取。
  8. MQL5: 修正了在继承时确认访问父类成员权限时的编译错误。
  9. MQL5: 修正了通过参数调整重载类方法的编译错误。
  10. 测试器: 优化了 MQL5 云网络代理的工作,现在,代理不需要时间来做所谓的"热身" - 连接云网络服务器并发布任务,代理一直可以接收和执行任务了,这加速了通过 MQL5 云网络进行的优化。
  11. 测试器: 提高了在策略测试器中本地,远端和云代理的展示状态,
  12. 修正了崩溃记录中报告的错误;
  13. 更新了文档。


MetaTrader 5 安卓版 build 1052

新版本的安卓版 MetaTrader 5 已经在 Google Play 可以下载,它包含了一些错误修正,并且提高了稳定性,很快会再加上分析对象和信息系统。

该应用程序可以在这里下载: https://download.mql5.com/cdn/mobile/mt5/android?hl=en&utm_source=www.metatrader5.com


更新可以通过 LiveUpdate 系统完成。

16 一月 2015
MetaTrader 5 平台在 Build 1045 中的更新: 新的 WebRequest

交易终端

  1. 用于支持在 MetaTrader 5 平台上虚拟主机的准备性工作。虚拟主机服务使您可以租用一个终端来持续运行而不会被您的 MetaTrader 5打断。它的一个主要特性是可以选择距离经纪商服务器最近的服务器而最小化网络延迟。




  2. 测试器代理现在只能在64位系统下工作了,这是由信息技术工业的发展而决定的,切换到新的技术提高了计算性能,也使 MQL5 云网络有进一步的发展。



    平台组件的变化:

    • 在32位终端中不能再使用远程代理和MQL5云网络代理了,会显示“只在64位版本中可用”的信息,而不是代理列表。
    • MetaTester 5 代理管理器只能在64位版本中使用,所以,只能在64位系统中安装代理。


  3. 当在终端设置中人工指定了语言列表时,会固定根据语言过滤新闻。
  4. 有很多开启的订单时进行了优化。
  5. 加速发送交易请求。
  6. 界面采用了高分辨率的屏幕 - 全高清乃至更高。

MQL5 语言

  1. 增加了 WebRequest 函数新的格式:
    int WebRequest (string method, string url,string headers,int timeout, const char &data[], int data_size,char &result[], string &result_headers)
    这个函数使您可以明确构建HTTP请求头部的内容,以提供更加灵活的机制来与各种Web服务作交互。

  2. 增加了新的交易账户属性,AccountInfoDouble 函数中可用的属性:

    • ACCOUNT_MARGIN_INITIAL - 账户中当前的初始保证金;
    • ACCOUNT_MARGIN_MAINTENANCE - 账户中当前的维持保证金;
    • ACCOUNT_ASSETS - 当前账户资产;
    • ACCOUNT_LIABILITIES - 当前账户负债;
    • ACCOUNT_COMMISSION_BLOCKED - 当前被阻止的账户手续费。

  3. 增加了新的交易品种属性:

    • SYMBOL_OPTION_STRIKE - 期权合约的预购价格,这个属性是通过 SymbolInfoDouble 函数得到的;
    • SYMBOL_BASIS - 交易品种的基础资产名称,这个属性是通过 SymbolInfoString 函数得到的;
    • SYMBOL_OPTION_MODE - 期权模式, 其数值是使用 ENUM_SYMBOL_OPTION_MODE 枚举设置的; 
    • SYMBOL_OPTION_RIGHT - 期权权利, 其数值是使用 ENUM_SYMBOL_OPTION_RIGHT 枚举设置的,属性是通过 SymbolInfoInteger 函数得到的;

  4. 增加了 SymbolInfoMarginRate 函数 - 取得初始和维持保证金的数值,它们是对应交易订单的类型和方向的;
  5. 修正了 ChartIndicatorName 函数在策略测试器中运行的问题;
  6. 修正了使用 ## 替换名称的宏的编译问题;
  7. 修正了当打开新文件时重置文件结束标志的问题;

修正了崩溃记录中报告的错误;

更新了文档。

这些更新内容将可以通过 LiveUpdate 系统进行更新。

12 十二月 2014
MetaTrader 5 Platform Update Build 1035: Option Strategy Builder and Access to Ticks

Trading Terminal

  1. Implementation of functions for trading options is currently underway. The Option Strategy Builder has been added. It helps users combine different options in one investment portfolio, and to assess the possibilities and potential risks.



    The Builder is easy to use: a trader chooses the option based on the expiration date and the underlying asset, and then selects one of the more than 30 available strategies. The Builder displays the appropriate combination of options and calculates evaluation parameters - the so-called Greeks. The profit/loss chart and the Greeks based chart appear at the bottom of the window.

    In addition to a large number of built-in strategies, traders can create and save their own strategies for later use.

  2. Added display of the number of newsletters received in the last 24 hours.




  3. Optimized and accelerated synchronization of large history of trading orders and deals.
  4. Fixed launch of several custom indicators in one chart subwindow.
  5. Fixed recalculation of Bill Williams Market Facilitation Index for a changed chart period.
  6. Fixed minimization of the "Toolbox window".
  7. Fixed generation of the account state report published over FTP.
  8. Updated translation of user interface into German.
  9. Added translation of user interface into Greek and Uzbek.

MQL5 Language

  1. New function for working with the tick history CopyTicks. The function is used for receiving an array of ticks accumulated by the terminal for the current session. The depth is limited to the last 2000 ticks.

    The new function expands the possibilities for developing scalping trading robots. The OnTick function does not handle every tick, it notifies the Expert Advisor of market changes. It can be a batch of changes: the terminal can simultaneously make a few ticks, but OnTick will be called only once to notify the EA of the latest market state. The CopyTicks function allows you to receive and analyze all the ticks.
    int  CopyTicks(
       const string      symbol_name,           // Symbol name
       MqlTick           &ticks_array[],        // the array where ticks will be placed
       uint              flags=COPY_TICKS_ALL,  // the flag that defines the type of received ticks
       ulong             from=0,                // the date starting from which ticks will be received, specified in milliseconds since 01.01.1970
       uint              count=0                // the number of latest ticks that should be received
       );
    Ticks can be requested by the date if the 'from' value is specified, or based on their number using the 'count' value. If none of the parameters are specified, all available ticks are received, but not more than 2000. Ticks can also be requested based on their type using the 'flags' parameter. Available values:

    • COPY_TICKS_ALL - all ticks.
    • COPY_TICKS_INFO - only information ticks (Bid and Ask).
    • COPY_TICKS_TRADE - only trade ticks (Last and Volume).

  2. Added an option for overloading template functions using array parameters.
  3. Added an option for overloading a method based on its constancy.
  4. Added generation of the CHARTEVENT_MOUSE_MOVE event (in the OnChartEvent entry point) at the right mouse button click on the chart.
  5. Fixed the functioning of the Switch operator if the case condition contains a negative value.
  6. Improved calculation accuracy in functions ObjectGetValueByTime() and ObjectGetTimeByValue(), used for receiving the price value for the specified object time and vice versa - time value for a price.

Strategy Tester

  1. MQL5 programs purchased in MetaTrader AppStore can now be tested and optimized on the MQL5 Cloud Network agents and on remote agents.
  2. Fixed calculation of swaps in points for positions with less than 1 lot.
  3. Fixed check and normalization of Stop Loss and Take Profit levels when opening a position for the trading instrument with "Market Execution" type.
  4. Fixed behavior of the ObjectGetValueByTime function. In some cases, the behavior of the function in the tester could be different from its behavior in the terminal.

MetaEditor

  1. Fixed MetaEditor crash when debugging and profiling looped programs.
  2. Added translation of user interface into Greek and Uzbek.

Fixed errors reported in crash logs.

Documentation has been updated.

The update is available through the LiveUpdate system.

31 十月 2014
MetaTrader 5 Trading Terminal build 1010: New Signals, Market and Options
Trading Signals
  1. The showcase of signals has been completely redesigned. New features have been added, the Signals service design and usability have been improved.



    The new features in the list of signals:

    • The list of signals now contains growth charts similar to those displayed on the MQL5.community site. A green icon in the lower left corner of the chart indicates that this is a real account based signal.
    • Now subscription to a signal is available directly from the list. To subscribe, press the button with the price indication (or the word 'Free', if the signal is free). This will open a subscription confirmation dialog.
    • Now signals can be added to Favorites. Click the star icon at the end of the signal line. After that, the signal can be easily found in the "Favorites" tab.
    • The context menu has been removed. Now to find a signal to which you have subscribed, go to any signal. The top panel shows the signal you are subscribed to and a link to it.

    A signal view page has been updated. A new option allows to add signals to Favorites. The status of the signal account is displayed when hovering the mouse pointer at "Growth".

    Signals statistics have expanded:

    • The total amount of subscribers' funds.
    • Trading account lifetime since its first trading operation.
    • The average position holding time.



    New tabs:

    • Risks - information about the best and worst trading operations and series of operations, and information on drawdowns.
    • Reviews - reviews of signal subscribers.
    • News - through this tab the signal provider can inform subscribers of any change in the signal and post other useful information.

Market

  1. Revised display of products in MetaTrader AppStore. Applications, magazines and books feature the new design. A new option allows to add products to Favorites. Click the star icon in the product view mode. After that, the product can be easily found in the "Favorites" tab.




Trading terminal

  1. The terminal now features an options board and a volatility chart. Implementation of tools for trading options is currently underway. Tools for analyzing option strategies will be added in the next version.




    Options Board
    The options board displays a series of options based on the expiration date for an underlying asset (a class of options) selected in the "Underlying" field. The following parameters are displayed for the options:

    • Bid CALL - the bid price of a call option.
    • Ask CALL - the ask price of a call option.
    • Theo CALL - the theoretical (fair) price of a call option calculated for the specified strike based on historical data.
    • Strike - an option execution price.
    • Volatility - an implied volatility. It is specified as a percentage, and characterizes the expectations of market participants about the value of the underlying asset of the option.
    • Theo PUT - the theoretical price of a put option calculated for the specified strike based on historical data.
    • Bid PUT - the bid price of a put option.
    • Ask PUT - the ask price of a put option.

    Volatility Chart
    Option strikes are shown along the horizontal axis of the chart, and the implied volatility is shown along its vertical axis.




  2. Added display of ping values ​​in the list of access points.




  3. The terminal interface has been adapted for high resolution screens - Full HD and higher. Menus, toolbars, window titles and the status bar are now large enough for easy viewing and working on touch screen of Windows-tablets.

  4. Added a command for managing trading symbols in the "View" menu and on the toolbar. Accessing symbol settings is now as easy as never before:



MQL5 Language

  1. Added conversion of a macro parameter to a string and concatenation of the macro parameter. Below is an example, in which the concatenation of macros allows to organize the automatic removal of the class instances.
    //+------------------------------------------------------------------+
    //|                                                     MacroExample |
    //|                        Copyright 2014, MetaQuotes Software Corp. |
    //|                                       https://www.metaquotes.net  |
    //+------------------------------------------------------------------+
    #property script_show_inputs
    input bool InpSecond=true;
    
    #define DEFCLASS(class_name) class class_name:public CBase{public:class_name(string name):CBase(name){}};
    #define TOSTR(x) #x
    #define AUTODEL(obj) CAutoDelete auto_##obj(obj)
    #define NEWOBJ(type,ptr) do { ptr=new type(TOSTR(ptr)); \
                             Print("Create object '",TOSTR(type)," ",TOSTR(ptr),"' by macro NEWOBJ"); } \
                             while(0)
    //+------------------------------------------------------------------+
    //| The basic class required for automatic deletion of objects       |
    //+------------------------------------------------------------------+
    class CBase
      {
    protected:
       string            m_name;
    
    public:
                         CBase(string name):m_name(name) { }
       string            Name(void) const{ return(m_name); }
    
      };
    //+------------------------------------------------------------------+
    //| The object auto-delete class makes watching of created           |
    //| objects unnecessary. It deletes them in its destructor           |
    //+------------------------------------------------------------------+
    class CAutoDelete
      {
       CBase            *m_obj;
    
    public:
                         CAutoDelete(CBase *obj):m_obj(obj) { }
                        ~CAutoDelete()
         {
          if(CheckPointer(m_obj)==POINTER_DYNAMIC)
            {
             Print("Delete object '",m_obj.Name(),"' by CAutoDelete class");
             delete m_obj;
            }
         }
      };
    //+------------------------------------------------------------------+
    //| Declaring two new classes CFoo and CBar                          |
    //+------------------------------------------------------------------+
    DEFCLASS(CFoo);
    DEFCLASS(CBar);
    //+------------------------------------------------------------------+
    //| The main script function                                         |
    //+------------------------------------------------------------------+
    void OnStart()
      {
       CFoo *foo;
    //--- Creating an object of the CFoo class
       NEWOBJ(CFoo,foo);
    //--- Creating an instance of the CFoo foo object auto-deletion class
       AUTODEL(foo);
    //---
       if(InpSecond)
         {
          CBar *bar;
          //---
          NEWOBJ(CBar,bar);
          AUTODEL(bar);
         }
    //--- No need to delete foo, it will be deleted automatically
      }
    //+------------------------------------------------------------------+
    
  2. Added the OBJPROP_ANCHOR property for the "Bitmap" and "Bitmap Label" objects. The property defines the anchor point of the graphical object on the chart: the upper left corner, center left, lower left corner, bottom center, etc.
  3. Added reading of the CHART_BRING_TO_TOP chart property (the chart is on top of all the others) in the ChartGetInteger function.
  4. Fixed the compilation and generation of the ternary operator "?".
  5. Fixed passing of a class member static array.
  6. Fixed applying of a template to the list of initialization of the template constructor class members.

Trading signals

  1. Restrictions on signal subscriptions became milder:

    If the trading history of the signal contains symbols that are not available in the subscriber's terminal, the subscription is now allowed (was prohibited in previous versions). The actions with the positions for which the subscriber does not have symbols are ignored. The following log appears in the Journal:
    2014.08.26 16:44:29.036    '2620818': Signal - symbol GBPNZD not found
    If the subscriber has positions and/or pending orders, a warning dialog suggesting to close/delete them appears (as before). Now, however, it is not an obligatory condition to continue working with signals.



    Synchronization with the signal provider will be performed. Positions and orders that were opened not based on the subscription signal are left unchanged. The user can perform any operations with them.

    Users can now perform trade operations manually (or using an Expert Advisor), being signed to a signal. The Signals service will ignore the positions and orders opened by the trader.
    Keep in mind that placing orders manually affects the amount of available margin on the trading account. Opening positions manually increases the overall load on the account as compared with the signal provider's account.
  2. Added support for a copied percent for the volumes with a floating point. The minimum percentage of copied volumes for signals has been reduced from 1% to 0.001%.

Strategy tester

  1. Fixed freezing of testing agents when working with the MQL5 Cloud Network.
  2. Fixed calculation of swaps in points for the minimal volumes of trading positions.

MetaEditor

  1. Fixed hotkeys for commands "Navigate Forward" and "Navigate Backward".

MetaViewer

  1. Fixed page navigation on the toolbar.
  2. Fixed text search based on the current interface language.

Fixed errors reported in crash logs.

Documentation has been updated.

The update is available through the LiveUpdate system.
1 八月 2014
MetaTrader 5 Trading Terminal build 975: Displaying Expert ID

Trading Terminal

  1. Added display of a trade ID (magic number) set by an Expert Advisor. The ID is displayed as a tooltip in the list of open positions and orders, as well as in the trading history.


    Displaying Expert ID


  2. Optimized work with a large number of trading symbols (thousands and tens of thousands).
  3. Fixed display of alerts on the price chart. The alert's price level was sometimes displayed in the indicator's subwindow.
  4. Updated interface translations into Chinese, Turkish and Japanese.
  5. Fixed displaying the list of chart templates in the application's main menu.
  6. Fixed displaying the list of trade symbol sets in the context menu of Market Watch window.

MQL5 Language

  1. Fixed errors in working with built-in structures that could occasionally disrupt the operation of IndicatorParameters and MarketBookGet methods.
  2. Fixed type conversion from bool to string.
  3. Fixed working with virtual functions.
  4. Fixed an error in the operation of FileReadStruct and FileWriteStruct functions within EX5 libraries.
  5. Fixed a compiler error that occurred in case a key word was present in a comment.

Strategy Tester

  1. Fixed calculation of swaps in points when testing.
  2. Fixed passing the file defined in #property tester_file. An error occurred if the file was in the common folder of the client terminals.
  3. Greatly improved selection of the nearest cloud server by the tester agents working within MQL5 Cloud Network of distributed computing. Thus, their operation speed is increased significantly.

MetaEditor

  1. Fixed text replacement when the list of MetaAssist tips is collapsed.

Fixed errors reported in crash logs.

Updated documentation.

The update is available through the LiveUpdate system.

27 六月 2014
MetaTrader 5 trading terminal build 965: Smart Search, OTP and Money Transfer between Accounts

Trading terminal

  1. Completely revised built-in search. The new search is a smart and powerful system. Search results are now conveniently arranged by categories.

    As you type in search query, the system instantly offers possible options:



    In order to search by one of the previous queries, place the cursor to the box and click Down Arrow key to open the query history. Selection of a search area is not available in the search bar any more, as the system automatically selects the most relevant results arranging them by categories conveniently:



    For better representation, search results now contain not only texts but also avatars of articles, books and applications. Use the top panel to view the search results by MetaTrader Appstore Products, Code Base, Signals, MQL5.community Forum and Documentation. If a category has no results, it is highlighted in gray.

  2. Added the OTP authentication feature. Use of OTP (one-time password) provides an additional level of security when working with trading accounts. The user is required to enter a unique one-time password every time to connect to an account.

    One-time passwords are generated in the MetaTrader 5 mobile terminal for iPhone . The same one-time password generation option will be added in the mobile terminal for Android soon.

    How to enable OTP
    To start using one-time passwords, a trading account should be bound to a password generator, which is the MetaTrader mobile terminal 5 for iPhone.
    The use of the OTP option should be enabled on a trade server.
    Go to the Settings of the mobile terminal and select OTP. For security reasons, when the section is opened for the first time, a four-digit password should be set. The password must be entered every time to access the password generator.



    In the window that opens, select "Bind to account".



    Next, specify the name of the server on which the trading account was opened, the account number and the master password to it. The "Bind" should be kept enabled. It must be disabled, if the specified account should be unbound from the generator and one-time passwords should no longer be used.

    After the "Bind" button located in the upper part of the window is tapped, a trading will be bound to the generator, and an appropriate message will appear.



    Likewise, an unlimited number of accounts can be bound to the generator.

    The one-time password is displayed at the top of the OTP section. Underneath, a blue bar visualizes the password lifetime. Once the password expires, it is no longer valid, and a new password will be generated.

    Additional Commands:

    • Change Password - change the generator password.
    • Synchronize Time - synchronize the time of the mobile device with the reference server. Accuracy requirement is connected with the fact that the one-time password is bound with the current time interval, and this time should be the same on the client terminal and the server side.

    How to use OTP in the desktop terminal
    After binding a trading account to the generator, a one-time password will be additionally requested when connecting to it from the desktop terminal:




  3. Added an option for transferring money between accounts within the same trade server. Money can be transferred only from the currently connected account. Select it in the "Navigator" window and click "Transfer funds" in the context menu.



    In the dialog box, select the account to which funds need to be transferred. The transfer amount is specified in the deposit currency of the current account. It cannot exceed the current balance and the current amount of free margin of the account.

    To transfer funds, a master password must be specified for both accounts. If OTP authentication is used for the account, from which funds are transferred, the one-time password should be additionally specified.

    Transfer of funds is provided in the form of balance operations: a withdrawal operation on the current account and depositing operation on the recipient account.
    • The money transfer option should be enabled on the trade server. Depending on the settings, there are some restrictions on the accounts, between which transfer is allowed. In particular, money transfer can be allowed only for accounts with identical names and emails.

    • Funds can be transferred only within the same trading server and only between the accounts of the same type. From a real account funds can be transferred only to another real account, from a demo one - only to demo.
    • The accounts, between which funds are transferred, should use the same deposit currency.
  4. Added an option for changing the password of any trading account in the "Navigator" window. Previously, it was possible to change the password only for the currently connected account.

    Now any account can be selected in the "Navigator" window and its passwords can be changed by clicking the appropriate command in the context menu:




  5. Added the possibility to set SL and TP levels on the chart by dragging the trade level of the corresponding position (using drag'n'drop). Hover the mouse over the level of the position on the chart. Click the left mouse button and hold it to move the level up or down.



    For long positions dragging down allows to set stop loss, up - take profit. And vice versa for short positions. When a level is dragged, the possible profit/loss in pips and currency, which may occur when this level triggers, is shown.

  6. Changed the location of commands in the "Window" menu. Now the "Tile window" option is displayed first, hotkeys Alt+R have been assigned for this command. This command has also been added to the standard toolbar.




  7. In the "Navigator" categories "Indicators" and "Custom Indicators" have been combined into one category "Indicators".



    All custom indicators, examples, and indicators purchased from the MetaTrader AppStore are now shown together with the built-in technical indicators. Four categories of built-in indicators are always displayed first.

  8. Revised the Navigator's context menu.

    Login has been renamed to "Login to Trade Account". Authentication in MQL5.community is available not only via the terminal settings but also via the context menus of the "Accounts" section and its subsections.



    The following changes have been implemented to the account's context menu:
    • Moved "Open an Account" command to the first position.
    • Added "Change Password" feature.
    • Added "Register a Virtual Server" command.

  9. Fixed display of the Label and Bitmap Label graphical objects with the anchor point located in one of the bottom corners of a chart.

MQL5 Language

  1. Added WebRequest() function for working with HTTP requests allowing MQL5 programs to interact with different websites and web services.

    The new function allows any EA to exchange data with third-party websites, perform trades based on the latest news and economic calendar entries, implement analytics, generate and publish automatic reports, read the latest quotes and do many other things that could previously be achieved only by using third-party DLLs of questionable reliability. The new feature is absolutely safe for traders, as they are able to manage the list of trusted websites the programs have access to.

    WebRequest function sends and receives data from websites using GET and POST requests. The new feature is absolutely safe for traders, as they are able to manage the list of trusted websites the programs have access to.




    This option is disabled by default for security reasons.

  2. Added access to signals database and managing signals subscription from MQL5 applications.

    Now, a user can receive the list of signals, evaluate them according to user-defined criteria, select the best one and subscribe to it automatically from a MQL5 program. In fact, it means the advent of the new class of trading robots that periodically look through available signals and subscribe to the one that is most suitable at the moment.

    For this purpose new signal management functions have been added to the MQL5 language:

    • SignalBase*() — functions for accessing the signals database.
    • SignalInfo*() — functions for receiving signal settings.
    • SignalSubscribe() and SignalUnsubscribe() — subscription management functions.

    Thus, a user can not only copy trades, but also to select signals for copying. Both processes are automated.

    By default, a trading robot is not allowed to change signal settings for security reasons. To enable this function, tick the "Allow modification of Signals settings" option in Expert Advisor settings.




  3. Added new properties of the client terminal that are available through the TerminalInfo* functions:
    • TERMINAL_MQID - the property shows that MetaQuotes ID is specified in terminal settings.
    • TERMINAL_COMMUNITY_ACCOUNT - this property shows that MQL5.community account is specified in the settings.
    • TERMINAL_COMMUNITY_ACCOUNT - this property shows that MQL5.community account is specified in the settings.
    • TERMINAL_COMMUNITY_BALANCE - value of balance on the MQL5.community account.
    • TERMINAL_NOTIFICATIONS_ENABLED - shows whether sending notifications through MetaQuotes ID is allowed.

  4. Added functions for working with cryptographic algorithms: CryptEncode() and CryptDecode(). These functions allow you to encrypt and decrypt the data, for example, when sending data over the network using the WebRequest() function. They also allow you to calculate checksums and make data archiving.

    Function signatures:
    int CryptEncode(ENUM_CRYPT_METHOD method,const uchar &data[],const uchar &key[],uchar &result[]);
    int CryptDecode(ENUM_CRYPT_METHOD method,const uchar &data[],const uchar &key[],uchar &result[]);
    A new enumeration ENUM_CRYPT_METHOD has been added for working with the functions:
    CRYPT_BASE64,      // BASE64 encryption (re-encoding)
    CRYPT_AES128,      // AES encryption with 128-bit key
    CRYPT_AES256,      // AES encryption with 256-bit key
    CRYPT_DES,         // DES encryption (key length is 56 bits - 7 bytes)
    CRYPT_HASH_SHA1,   // calculation of HASH SHA1
    CRYPT_HASH_SHA256, // calculation of HASH SHA256
    CRYPT_HASH_MD5,    // calculation of HASH MD5
    CRYPT_ARCH_ZIP,    // ZIP archive

  5. Added an option for changing the size of the properties dialog of MQL5 programs.




  6. Added ability to debug the template functions.
  7. Added definition of the custom indicators that are executed too slowly. If the indicator is slow, "indicator is too slow" entry appears in the Journal.
  8. Fixed the value returned by the IsStopped() function. This function is used for determining the forced stopping of MQL5 programs in custom indicators. Previously, this function always returns FALSE.
  9. Fixed verification of input parameters of MQL5 programs by data type. In particular, for the parameter type uchar, one could specify a value greater than 255.
  10. Fixed an error in StringConcatenate() function.
  11. Fixed FileSize() function for files that are available for writing. Previously, the function returned the file size without considering the latest write operations.
  12. File operations have been revised. Now work with files has become faster.

Trading Signals

  1. Fixed copying of SL and TP values of trade positions in case the number of decimal places in the symbol price of the signal source differs from that of the subscriber.
  2. Fixed copying of trade positions from signal providers with incorrect settings of trade instruments on the side of the trade server.
  3. Fixed closing of positions opened by a trading signal when account Equity value falls below the value specified in the signal copying parameters. In some cases, closing of positions could lead to terminal crash.

MetaEditor

  1. Optimized work with large source text files (tens of megabytes). Increased operation speed and reduced memory consumption.
  2. Fixed navigating through a source code using "Ctrl + -" and "Ctrl + Shift + -" shortcuts.

Fixed errors reported in crash logs.

Updated documentation.

The update will be available through the LiveUpdate system.

11 四月 2014
MetaTrader 5 Build 930

Market

  1. Another new product category has been added to MetaTrader AppStore following trading and financial magazines - Books. Now, you can purchase the works of well-known traders and analysts along with trading robots and indicators. The range of books is increasing daily.


    Books in MetaTrader Market

    Just like MetaTrader 5 applications, books can be purchased at MQL5.community Market as well as directly via MetaTrader 5 terminal. All books are accompanied by descriptions and screenshots:




    Before making a purchase, you can download a preview - the first few pages of a book. The exact number of available pages is defined by a seller.

    To buy a book, you should have an MQL5.com account and the necessary amount of funds on it. The account data should be specified at the Community tab of the terminal settings:



    Click Buy on the book's page to purchase it. Purchase confirmation dialog appears:



    To continue, agree to the rules of using the Market service and enter your MQL5.community password. After that, the specified amount of funds will be withdrawn from your account and the book will be downloaded. Buy button will be replaced by Open one.

    Book files are downloaded to My Documents\MQL5 Market\Books\. The download may be performed in two formats:

    • MQB - this protected format is used for paid books. When purchasing and downloading a book file, it is encoded so that it can be opened only on the PC it has been downloaded to. Generation of an encoded copy is called activation. Each book can be activated at least 5 times on different hardware. Book sellers can increase the number of activations at their sole discretion.
    • PDF - this format is used for free books and previews. After downloading, such file can be moved and viewed on other devices.

    The special component called MetaViewer has been added to MetaTrader 5 terminal allowing users to view book files. MetaViewer is a convenient application for viewing books and magazines in MQB and PDF formats. Keyboard arrows are used to turn over the pages: left and right arrows - for page-by-page navigation, while up and down arrows - for scrolling.


    MetaViewer


Trading terminal

  1. Fixed display of Fibonacci Fan graphical object's levels when zooming. A layout could be displaced in earlier builds.
  2. Fixed an error that in some cases prevented graphical objects from being drawn on the chart.
  3. Fixed errors and terminal crashes when working in Wine (for Linux and Mac OS), including crashes that occurred while opening the user guide.
  4. Updated translation of the interface into Arabic.

Market

  1. Revised display of products in MetaTrader AppStore. Applications, magazines and books feature new design:


    Revised Display of Products in Market

  2. Market: Fixed resumed download of large files (primarily, magazines and books) from the Market.

MQL5 Language

  1. Changed StringSplit function operation. Previously, ";A;" string was split into NULL and "A" substrings using ';' separator. Now, it is split into "","A" and "" substrings.
  2. Fixed checking and tracking parameter and operand constancy.

Trading Signals

  1. Added additional checks for the allowed trading modes at a symbol when copying signals. If a signal arrives at a subscriber's account but only closing of positions is allowed at that symbol, this will no longer cause complete termination of signals copying and forced closing of all positions. Now, if a signal for position opening arrives at a subscriber's account, the platform perceives that as the command to synchronize subscriber's and provider's accounts. A signal for position closing is handled as usual.

Strategy Tester

  1. Added interface translations into French, Japanese and Arabic. Updated translations into German, Italian, Polish, Portuguese, Russian, Spanish, Turkish and Chinese.

MetaEditor

  1. Fixed highlighting and navigation through a hieroglyphic text.
  2. Fixed selecting a default trading symbol during an MQL5 application profiling. The default symbol is specified in Debug tab of MetaEditor options.
  3. Fixed display of the tab characters in search results. Previously, the tab characters were ignored and string content was displayed with no spaces.

Fixed errors reported in crash logs.

Updated documentation.

The update will be available through the LiveUpdate system.

7 三月 2014
MetaTrader 5 build 910

Trading terminal

  1. Fixed errors and crashes when working in Wine (for Linux, Mac).
  2. Fixed display of Gann Grid graphical object's central line when zooming.

MQL5 Language

  1. Fixed an occasional error when downloading .ex5 files.
  2. Fixed operation of StringToCharArray and StringToTime functions.
Fixed errors reported in crash logs.
Updated documentation.
28 二月 2014
MetaTrader 5 Build 900
  1. Market: Added new product category in MetaTrader AppStore — Magazines. Now, users can buy not only trading applications but also trading and financial magazines quickly and easily.

    Just like MetaTrader 5 applications, magazines can be purchased at MQL5.community Market as well as directly via MetaTrader 5 terminal. All magazines are accompanied by detailed descriptions and screenshot galleries:

    The latest magazine issues are always displayed in the showcase, while the previous ones can be found on the Archive tab.

    To buy a magazine, you should have an MQL5.com account and the necessary amount of funds on it. The account data should be specified at the Community tab of the terminal settings:

    Click Buy on the magazine's page to purchase it. Purchase confirmation dialog appears:

    To continue, agree to the rules of using the Market service and enter your MQL5.community password. After that, the specified amount of funds will be withdrawn from your account and the magazine will be downloaded. Buy button will be replaced by Open one.

    Magazine files are downloaded to My Documents\MQL5 Market\Magazines\[Magazine name]\[Issue name]. The download may be performed in two formats:

    • MQB - this protected format is used for paid magazines. When purchasing and downloading a magazine file, it is encoded so that it can be opened only on the PC it has been downloaded to. Generation of an encoded copy is called activation. Each magazine can be activated at least 5 times on different hardware. Magazine sellers can increase the number of activations at their sole discretion.

    • PDF - this format is used for free magazines. After downloading, such file can be moved and viewed on other devices.

    The special component called MetaViewer has been added to MetaTrader 5 terminal allowing users to view MQB files. This application is launched when you click Open at the downloaded magazine page. If User Account Control system is enabled on the user's PC, the user will be prompted to allow the terminal to associate MQB files with MetaViewer during the first launch. After the association, MQB files are automatically opened in MetaViewer when launched from Windows file explorer.

    If you click ÎÊ, the files are associated and the selected magazine issue is opened in MetaViewer immediately. If you click Cancel, only the magazine issue is opened.

    MetaViewer is a convenient application for viewing books and magazines in MQB and PDF formats. Keyboard arrows are used to turn over the pages: left and right arrows - for page-by-page navigation, while up and down arrows - for scrolling. MetaViewer menu and control panel contain additional commands for setting the journal's view and navigation:

    • File - commands for opening the files and exiting the program.
    • View - display settings: interface language, page look, enabling control panel and status bar, as well as page rotation.
    • Navigation - navigation commands: switching between the pages, moving to the first, last or selected page.
    • Zoom - page scale management commands: zooming in and out, fitting height, width and actual page size.
    • Help - information about the program and useful links.
  2. Terminal: Added MQL tab to EX5 file properties. The tab contains the program's icon as well as its name and description specified in the application's source code via the appropriate #property parameters.

    The tab appears only after MetaViewer is registered in the system. If a current user has sufficient rights and User Account Control system is disabled, MetaViewer is registered automatically during the terminal's first launch after the update. Otherwise, the user will see the dialog window requesting a one-time elevation of rights for MetaViewer during the first attempt to open a magazine.

  3. Terminal: Added MQL5.community fast registration dialog in case a user has no account. Now, an MQL5.community account can be created without the need to leave the terminal.

    Specify login and email address in the registration window. After clicking Register, an email for MQL5.community account activation is sent to the specified address.

    MQL5.community account allows traders to use additional powerful services:

    • MetaTrader 5 AppStore - users can buy MetaTrader 5 apps or download them for free directly from the terminal. MetaTrader 5 AppStore offers hundreds of various applications and their number is constantly increasing.
    • Signals - users can subscribe to trading signals provided by professional traders and make profit. Trading operations are automatically copied from provider's account to subscriber's one. The service also allows selling your own trading signals. A trading account can be connected to the monitoring system in a few clicks.
    • Jobs - a freelance service allowing customers to securely order the development of MetaTrader 4 and 5 applications. The orders are executed by experienced programmers. The service also allows you to make profit by developing programs ordered by customers.

  4. Terminal: Added information about margin charging rates for various order types, as well as the list of spreads that may include orders and positions for the symbol, to the trading symbol data dialog.

    Margin Rates:

    A multiplier for calculating margin requirements relative to the margin's main amount is specified for each order type. The main amount of margin is calculated depending on the specified calculation method (Forex, Futures, etc.).

    • Long positions rate
    • Short positions rate
    • Limit orders rate
    • Stop orders rate
    • Stop-Limit orders rate

    Calculation of margin requirements is described in details in the client terminal user guide.

    Spreads:

    The margin can be charged on preferential basis in case trading positions are in spread relative to each other. The spread is defined as the presence of the oppositely directed positions at related symbols. Reduced margin requirements provide traders with more trading opportunities.

    The spread has two legs - A and B. The legs are the oppositely directed positions in a spread - buy or sell. The leg type is not connected with some definite position direction (buy or sell). It is important that trader's positions at all leg's symbols are either long or short.

    Several symbols with their own volume rates can be set for each spread leg. These rates are shown in parentheses, for example, LKOH-3.13 (1).

    Take a look at the following example:

    • leg À consists of GAZR-9.12 and GAZR-3.13 symbols having the ratios of 1 and 2 respectively;
    • leg  consists of GAZR-6.13 symbol having the ratio of 1.

    To keep positions in the spread, a trader should open positions of 1 and 2 lots for GAZR-9.12 and GAZR-3.13 respectively in one direction and a position of 1 lot for GAZR-6.13 in another.

    Margin column displays margin charging type at this spread:

    • Specific values mean charging a fixed margin for a spread in a specified volume. The first value specifies the volume of the initial margin, while the second one specifies the volume of the maintenance one.

    • Maximal - initial and maintenance margin values are calculated for each spread leg. The calculation is performed by summing up the margin requirements for all leg symbols. The margin requirements of the leg having a greater value will be used for the spread.

    • CME Inter Spread - the rates (in percentage value) for margin are specified: the first one is for the initial margin, while the second is for the maintenance one. The total margin value will be defined by summing up the margin requirements for all symbols of the spread and multiplying the total value by the specified rate.

    • CME Intra Spread - two values for margin increase are specified: the first value is for the initial margin, while the second is for the maintenance one. During the calculation, the difference between the total margin of A leg symbols and the total margin of B leg symbols is calculated (the difference in absolute magnitude is used, so that it does not matter what leg is a deductible one). According to the type of the calculated margin, the first (for the initial margin) or the second (for the maintenance one) value is added to the obtained difference.

    The specified margin is charged per spread unit - for the specified combination of positions. If any part of the position does not fit the spread, it will be charged by an additional margin according to the symbol settings. If the client's current positions have the volume the specified combination fits in several times, the charged margin is increased appropriately. For example, suppose that A and B symbols with the ratios of 1 and 2 are in spread. If a client has positions for these symbols with the volumes of 3 and 4 respectively, the total margin size is equal to the doubled value from the spread settings (two spreads: 1 lot of A and 2 lots of B, 1 lot of A and 2 lots of B) plus the margin for the single remaining A symbol lot.

    Spreads are described in details in the client terminal user guide.

  5. Terminal: Fixed the depth of market freezing when the best bid price is higher than the best ask one.
  6. Terminal: Fixed setting the fill policy type for market trade requests depending on the trade symbol's execution type and allowed filling modes.
  7. Terminal: Fixed display of incorrect SL and TP values in the position open dialog in case there is a position with placed SL and TP levels and the levels are placed "In Points". Incorrect SL and TP level values in points have previously been inserted to these fields. Beginning with the new build, the values in the above mentioned case are displayed in prices regardless of the level placing mode.
  8. Terminal: Fixed occasional incomplete display of the trading history for the current day.
  9. Terminal: Reduced memory consumption during MQL5 Code Base and MQL5 Market operation.
  10. Terminal: Fixed working with context menus when using touch screen devices powered by Microsoft Windows 8 or higher.
  11. Market: Added product activation confirmation dialog displaying the number of remaining activations.

    Each application purchased in MetaTrader AppStore is additionally protected, so that it can be launched only on the PC it has been downloaded to during the purchase. Generation of an encoded copy is called activation. Each product can be activated at least 5 times on different hardware. Sellers can increase the number of activations at their sole discretion.

    The new dialog protects users from wasting activations by informing that their number is limited.

  12. MQL5: Fixed crash when initializing primitive type arrays by a sequence.
  13. MQL5: Fixed errors when working with #ifdef/#else/#endif conditional compilation macros.
  14. MQL5: MQL5 language compiler moved to MetaEditor. The compiler will be available for download as a separate .exe file.
  15. Signals: Added information about a signal, to which an account is subscribed, to the Navigator window:

    If the account is subscribed to the signal, the appropriate icon with the signal's name is shown for it. When hovering the mouse cursor over the name, the subscription's expiration date is displayed. The context menu contains commands for viewing the signal and unsubscribing from it. The latter one is displayed only if the appropriate trading account is currently active in the terminal.

    The subscription icon makes working with signals more convenient.

  16. Signals: Added legend for equity, growth, balance and distribution graphs. Also, marks displaying funds depositing and withdrawal have been added to the equity graph. When hovering the mouse cursor over the balance operation triangle, a tooltip with the operation sum is displayed:

  17. MetaEditor: Fixed the loss of focus in the code editing window that occurred after the first compilation.
  18. MetaEditor: Fixed automatic scrolling of the compilation window to the first warning if there are no errors.
  19. MetaEditor: Fixed highlighting predefined _DEBUG and _RELEASE macros in the source code.
  20. MetaEditor: Fixed operation of snippets if the automatic entering of line indentations is disabled.
  21. Fixed errors reported in crash logs.
  22. Updated documentation.
7 十二月 2013
MetaTrader 5 Trading Terminal build 880: Terminal Journal with Milliseconds and MQL4BUILD/MQL5BUILD Macros

Trading Terminal

  1. The time is displayed up to milliseconds in the client terminal's, MetaEditor's and MetaTester's Journal.

    The time is displayed up to milliseconds in the client terminals

  2. Improved scanning and searching for servers in demo account opening dialog - scanning speed has been increased and additional search for access points for the servers having no connection has been added.

    Improved scanning and searching for servers in demo account opening dialog

  3. Fixed and optimized client terminal, MetaEditor and MQL5 help.
  4. origin.txt file is automatically generated in the terminal data folder. This file contains the path to the installation directory that data folder corresponds to.
  5. Fixed display of the context help in a number of dialogs, windows and control elements.
  6. Fixed occasional terminal freezing during prolonged continuous operation (longer than 2-3 days).
  7. Fixed occasional loss of the list of saved client accounts.
  8. Fixed an error causing "pack bar error" messages in the Journal.
  9. Added MetaTrader 5 terminal and MQL5 language helps in Turkish

Market

  1. Fixed and optimized MQL5 Market data storage and update.

MQL5

  1. Fixed an error in overloading the function templates.
  2. Added __MQL4BUILD__ and __MQL5BUILD__ macros - MQL5 compiler versions in MetaTrader 4 and MetaTrader 5 client terminals respectively. These macros can be used for displaying information about the compiler version used for compiling EX4\EX5 file in Experts log of the client terminal:

    //+------------------------------------------------------------------+
    //| Expert initialization function                                   |
    //+------------------------------------------------------------------+
    int OnInit()
      {
    //---
       Print(__FILE__," compiled with ",__MQL5BUILD__," build");
    //---
       return(INIT_SUCCEEDED);
      }

MetaTrader Trading Signals

  1. Fixed comparison of Forex trading symbols of EURUSD <=> EURUSD.ABC form in case there are several symbols having similar main part (EURUSD), and trading is disabled for one of them.
  2. Fixed signals copying when performing balance and credit operations on the subscriber's account. The total amount of client's funds is changed after a balance/credit operation is performed. If the percentage value of signals copying has decreased by more than 1% afterwards (the volume of copied trades is calculated considering the ratio of the subscriber's and provider's balance), the subscriber's account is forcedly synchronized with the provider's one. This is done to correct the subscriber's current positions according to the new copying percentage value.

    If the subscriber's funds have increased due to the balance or credit operation, no forced synchronization is performed.

  3. Fixed copying positions in case Fill or Kill (FOK) market order execution mode is forbidden.

MetaEditor

  1. Fixed working with the clipboard when inserting non-Unicode text.
  2. Fixed scrolling the navigator tree when moving folders using drag'n'drop

Fixed errors reported in crash logs.
Updated documentation.

The live update is available through the LiveUpdate system.

The MetaTrader 5 Trading Terminal can be downloaded at https://download.mql5.com/cdn/web/metaquotes.ltd/mt5/mt5setup.exe?utm_source=www.metatrader5.com

12345678910111213