比特币通信协议 - 币圈消息

比特币通信协议篇11、二、TURN简介。在典型的情况下,TURN客户端连接到内网中,并且通过一个或者多个NAT到 详细

来个人帮我看看这程序编写的哪有问题?

[复制链接]
151 0
顺水的鱼 发表于 2017-5-7 18:50:00 | 只看该作者 |阅读模式 打印 上一主题 下一主题
extern double LotSize=0.1;
extern double stopLoss=50;
extern double Takeprofit=100;
extern int Slippage=5;
extern int MagicNumber=123;
extern int FastMAperiod=10;
extern int SlowMAperiod=20;
//Global. variables
int BuyTicket;
int SellTicket;
double UsePoint;
int UseSlippage;
//int function
//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
int init
  {
//---
   UsePoint=PipPoint);
   UseSlippage=GetSlippage,Slippage);
//---
   return;
  }
//+------------------------------------------------------------------+
//| Expert Start function                                            |
//+------------------------------------------------------------------+
int start
  {
//Moving averages
    double FastMA=iMa;
    double SlowMA=iMa;
  
//Buy order
    if  
      {
        OrderSelect;
//Close order
        if==0&&SellTicket>0)
           {
             double CloseLots=OrderLots;
             double ClosePrice=Ask;
             boot Closed=OrderClose;
           }
        double OpenPrice=Ask;           
//Calculate stop loss and take profit
        ifdouble BuyStopLoss=Openprice-;
        ifdouble BuyTakeProfit=OpenPrice+;
        
//Open buy order
        BuyTicket=OrderSend,OP_BUY,LotSize,OpenPrice,UseSlippage,BuyStopLoss,BuyTakeProfit,"Buy Order",MagicNumber,0,Green);
        SellTicket0;
       }
//Sell Order
    if
      {
        OrderSelect;
        if==0&&BuyTicket>0)
          {
            CloseLots=OrderLots;
            ClosePrice bid;
            Closed=OrderClose;
          }  
        OpenPrice=Bid;
        
        ifdouble SellStopLoss=OpenPrice+;
        ifdouble SellTakeProfit=OpenPrice-;
        
        SellTicket=OrderSend,OP_SELL,LotSize,Openprice,UseSlippage,SellStopLoss,SellTakeProfit,"Sell Order",MagicNumber,0,Red);
        BuyTicket=0;
      }   
     return;
  }
//Pip Point Function
double Pippoint
   {
     int CalcDigits=MarketInfo;
     ifdouble CalcPoint=0.01;
     else if CalcPoint=0.001;
     return;
   }
//GetSlippage Function
int GetSlippage
    {
       int CalcDigits=MarketInfo;
       {
         ifdouble CalcSlippage=SlippagePips;
         else if CalcSlippage=SlippagePips*10;
       }
      return;
    }
收藏
收藏0
转播
转播
分享
分享
分享
淘帖0
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

发布主题
阅读排行更多+

Powered by 顺水鱼MT4外汇EA网! X3.2© 2001-2017 顺水MT4外汇EA公司.( 陕ICP备17014341号-1