下载MetaTrader 5
要添加评论,请登录注册
下载MetaTrader 5的iPad版和在各地进行交易!
OldZ
122
OldZ 2010.03.29 05:07 





//+------------------------------------------------------------------+
//|                                            BasketTrade_10Buy.mq4 |
//|                       Copyright ?2010, MetaQuotes Software Corp. |
//|                                        http://www.metaquotes.net |
//+------------------------------------------------------------------+

// This is a script instead of indicator.
#property copyright "Copyright ?2010, MetaQuotes Software Corp."
#property link      "http://www.metaquotes.net"
extern double Lot = 0.1;


//+------------------------------------------------------------------+
//| script program start function                                    |
//+------------------------------------------------------------------+
int start()
  {
//----
// Group 1, BASE USD
   OrderSend("EURUSD",OP_BUY, Lot, MarketInfo("EURUSD",MODE_ASK), 2, NULL, NULL, "Group1", 0, 0, CLR_NONE);
   OrderSend("GBPUSD",OP_BUY, Lot, MarketInfo("GBPUSD",MODE_ASK), 2, NULL, NULL, "Group1", 0, 0, CLR_NONE);
   OrderSend("AUDUSD",OP_BUY, Lot, MarketInfo("AUDUSD",MODE_ASK), 2, NULL, NULL, "Group1", 0, 0, CLR_NONE);
   
//Group 2  BASE JPY
    OrderSend("EURJPY",OP_BUY, Lot, MarketInfo("EURJPY",MODE_ASK), 2, NULL, NULL, "Group2", 0, 0, CLR_NONE);
    OrderSend("GBPJPY",OP_BUY, Lot, MarketInfo("GBPJPY",MODE_ASK), 2, NULL, NULL, "Group2", 0, 0, CLR_NONE);
    OrderSend("AUDJPY",OP_BUY, Lot, MarketInfo("AUDJPY",MODE_ASK), 2, NULL, NULL, "Group2", 0, 0, CLR_NONE);
    
// Group3   NON USD OR JPY
    
   OrderSend("EURGBP",OP_BUY, Lot, MarketInfo("EURGBP",MODE_ASK), 2, NULL, NULL, "Group3", 0, 0, CLR_NONE);
   OrderSend("EURAUD",OP_BUY, Lot, MarketInfo("EURAUD",MODE_ASK), 2, NULL, NULL, "Group3", 0, 0, CLR_NONE);   
   OrderSend("GBPAUD",OP_BUY, Lot, MarketInfo("GBPAUD",MODE_ASK), 2, NULL, NULL, "Group3", 0, 0, CLR_NONE);

//Group 4
   OrderSend("USDJPY",OP_BUY, Lot, MarketInfo("USDJPY",MODE_ASK), 2, NULL, NULL, "Group4", 0, 0, CLR_NONE);
   

//----
   return(0);
  }
//+------------------------------------------------------------------+

yijun lan
190
yijun lan 2010.04.11 07:30  

extern double Lot = 0.1;

int start()
{
// Group 1, BASE USD
OrderSend("EURUSD",OP_BUY, Lot, MarketInfo("EURUSD",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
OrderSend("GBPUSD",OP_BUY, Lot, MarketInfo("GBPUSD",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
OrderSend("AUDUSD",OP_BUY, Lot, MarketInfo("AUDUSD",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
//Group 2 BASE JPY
OrderSend("EURJPY",OP_BUY, Lot, MarketInfo("EURJPY",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
OrderSend("GBPJPY",OP_BUY, Lot, MarketInfo("GBPJPY",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
OrderSend("AUDJPY",OP_BUY, Lot, MarketInfo("AUDJPY",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
// Group3 NON USD OR JPY
OrderSend("EURGBP",OP_BUY, Lot, MarketInfo("EURGBP",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
OrderSend("EURAUD",OP_BUY, Lot, MarketInfo("EURAUD",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
OrderSend("GBPAUD",OP_BUY, Lot, MarketInfo("GBPAUD",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
//Group 4
OrderSend("USDJPY",OP_BUY, Lot, MarketInfo("USDJPY",MODE_ASK), 2, 0, 0, "", 0, 0, CLR_NONE);
return(0);
}

/
要添加评论,请登录注册