SavvyKuPower
Active Member
- Messages
- 1,014
- Joined
- Aug 13, 2009
- Messages
- 1,014
- Reaction score
- 246
- Points
- 33
nak jadi pilot pun bukan leh masuk cokpit trus..kene blajar tools kat cokpit tu..hehe..tak gitu 
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
saya nak belajar teknik nih tapi masih tidak berkesempatan nak gi opis kat kl.. kalu ada sesapa dari kulai@jb sila pm saya... kongsi kan la ilmu tu pada saya... dah baca dan demo but still jammed
Salam masta coder.Ada sedikit permintaanlaa..err ada simpan lagi tak script buy and sell serentak tuh?Computer kena serangan virus..format habis semua hilang..thanks..Max bar in history tak guna pc resource. Yang guna resource ialah max bar in chart. Jangan letak tinggi sangat melainkan bro nak backtest ea

Salam masta coder.Ada sedikit permintaanlaa..err ada simpan lagi tak script buy and sell serentak tuh?Computer kena serangan virus..format habis semua hilang..thanks..
Katakan aku trade 13 pair..3 aku nak buat sell,10 aku nak buat buy..haa nak script yg mcm tulaa...hehe..ada?wahh masta ini jam dah main inter market utk analisa yer...power...i follow..aku bkn master coder, tp, kot bleh tolong
yang mana satu?
Katakan aku trade 13 pair..3 aku nak buat sell,10 aku nak buat buy..haa nak script yg mcm tulaa...hehe..ada?wahh masta ini jam dah main inter market utk analisa yer...power...i follow..
Kita ada 4 pilihan:Kalau kamu long/Short semuanya pun tak akan MC..

//+------------------------------------------------------------------+
//| multi order.mq4 |
//| Copyright © 2009, MetaQuotes Software Corp. |
//| http://www.metaquotes.net |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2009, 1000 pips club."
#property link "www.oasiswealthbuilders.com"
// allow script to accept inputs from user
#property show_inputs
//user input
extern double Lots =0.2;
int SL =0;
int TP =0;
extern int maxSpread =10;
extern string info1 ="0=no trade, 1=buy, 2=sell";
extern int EURUSD =0;
extern int GBPUSD =0;
extern int AUDUSD =0;
extern int USDJPY =0;
extern int USDCHF =0;
extern int USDCAD =0;
extern int EURAUD =0;
extern int EURCAD =0;
extern int EURCHF =0;
extern int EURGBP =0;
extern int EURJPY =0;
extern int GBPJPY =0;
extern int GBPCHF =0;
extern int NZDUSD =0;
extern int AUDCAD =0;
extern int AUDJPY =0;
extern int CHFJPY =0;
extern int AUDNZD =0;
extern int NZDJPY =0;
extern int NZDCAD =0;
extern int NZDCHF =0;
extern int GBPNZD =0;
extern int EURNZD =0;
extern int GBPCAD =0;
extern int GBPAUD =0;
extern int AUDCHF =0;
extern int CADCHF =0;
extern int CADJPY =0;
int Slippage = 3;
// globals
string mySymbol, postfix;
double ask, bid, point, SLBuy, SLSell, TPBuy, TPSell;
int MagicNumber=12345678;
// used for verbose error logging
#include <stdlib.mqh>
//+------------------------------------------------------------------+
//| script program start function |
//+------------------------------------------------------------------+
int init()
{
postfix=StringSubstr(Symbol(),6,1);
if (EURUSD==1) OpenPos("EURUSD", "Buy");
if (EURUSD==2) OpenPos("EURUSD", "Sell");
if (GBPUSD==1) OpenPos("GBPUSD", "Buy");
if (GBPUSD==2) OpenPos("GBPUSD", "Sell");
if (AUDUSD==1) OpenPos("AUDUSD", "Buy");
if (AUDUSD==2) OpenPos("AUDUSD", "Sell");
if (USDJPY==1) OpenPos("USDJPY", "Buy");
if (USDJPY==2) OpenPos("USDJPY", "Sell");
if (USDCHF==1) OpenPos("USDCHF", "Buy");
if (USDCHF==2) OpenPos("USDCHF", "Sell");
if (USDCAD==1) OpenPos("USDCAD", "Buy");
if (USDCAD==2) OpenPos("USDCAD", "Sell");
if (EURAUD==1) OpenPos("EURAUD", "Buy");
if (EURAUD==2) OpenPos("EURAUD", "Sell");
if (EURCAD==1) OpenPos("EURCAD", "Buy");
if (EURCAD==2) OpenPos("EURCAD", "Sell");
if (EURCHF==1) OpenPos("EURCHF", "Buy");
if (EURCHF==2) OpenPos("EURCHF", "Sell");
if (EURGBP==1) OpenPos("EURGBP", "Buy");
if (EURGBP==2) OpenPos("EURGBP", "Sell");
if (EURJPY==1) OpenPos("EURJPY", "Buy");
if (EURJPY==2) OpenPos("EURJPY", "Sell");
if (GBPJPY==1) OpenPos("GBPJPY", "Buy");
if (GBPJPY==2) OpenPos("GBPJPY", "Sell");
if (GBPCHF==1) OpenPos("GBPCHF", "Buy");
if (GBPCHF==2) OpenPos("GBPCHF", "Sell");
if (NZDUSD==1) OpenPos("NZDUSD", "Buy");
if (NZDUSD==2) OpenPos("NZDUSD", "Sell");
if (AUDCAD==1) OpenPos("AUDCAD", "Buy");
if (AUDCAD==2) OpenPos("AUDCAD", "Sell");
if (AUDJPY==1) OpenPos("AUDJPY", "Buy");
if (AUDJPY==2) OpenPos("AUDJPY", "Sell");
if (CHFJPY==1) OpenPos("CHFJPY", "Buy");
if (CHFJPY==2) OpenPos("CHFJPY", "Sell");
if (AUDNZD==1) OpenPos("AUDNZD", "Buy");
if (AUDNZD==2) OpenPos("AUDNZD", "Sell");
if (NZDJPY==1) OpenPos("NZDJPY", "Buy");
if (NZDJPY==2) OpenPos("NZDJPY", "Sell");
if (NZDCAD==1) OpenPos("NZDCAD", "Buy");
if (NZDCAD==2) OpenPos("NZDCAD", "Sell");
if (NZDCHF==1) OpenPos("NZDCHF", "Buy");
if (NZDCHF==2) OpenPos("NZDCHF", "Sell");
if (GBPNZD==1) OpenPos("GBPNZD", "Buy");
if (GBPNZD==2) OpenPos("GBPNZD", "Sell");
if (EURNZD==1) OpenPos("EURNZD", "Buy");
if (EURNZD==2) OpenPos("EURNZD", "Sell");
if (GBPCAD==1) OpenPos("GBPCAD", "Buy");
if (GBPCAD==2) OpenPos("GBPCAD", "Sell");
if (GBPAUD==1) OpenPos("GBPAUD", "Buy");
if (GBPAUD==2) OpenPos("GBPAUD", "Sell");
if (AUDCHF==1) OpenPos("AUDCHF", "Buy");
if (AUDCHF==2) OpenPos("AUDCHF", "Sell");
if (CADCHF==1) OpenPos("CADCHF", "Buy");
if (CADCHF==2) OpenPos("CADCHF", "Sell");
if (CADJPY==1) OpenPos("CADJPY", "Buy");
if (CADJPY==2) OpenPos("CADJPY", "Sell");
}
int start() {}
//ENTRY LONG (buy, Ask)
void OpenPos(string sym, string Trade)
{
mySymbol=sym+postfix;
int gle=0;
int ticket=0;
int loopcount;
bid=MarketInfo(mySymbol,MODE_BID);
ask=MarketInfo(mySymbol,MODE_ASK);
point=MarketInfo(mySymbol,MODE_POINT);
loopcount=0;
if (MarketInfo(mySymbol, MODE_SPREAD)<maxSpread)
{
while(true)
{
if (SL>0) { SLBuy=bid-(SL*point); SLSell=ask+(SL*point); }
if (TP>0) { TPBuy=bid+(TP*point); TPSell=ask-(TP*point); }
if (Trade=="Buy") ticket=OrderSend(mySymbol,OP_BUY,Lots,ask,Slippage,SLBuy,TPBuy,"",MagicNumber,White);
if (Trade=="Sell") ticket=OrderSend(mySymbol,OP_SELL,Lots,bid,Slippage,SLSell,TPSell,"",MagicNumber,Red);
gle=GetLastError();
if(gle==0)
{
if (Trade=="Buy") Print("BUY PLACED Ticket="+ticket+" Ask="+ask+" Lots="+Lots);
if (Trade=="Sell") Print("SELL PLACED Ticket="+ticket+" Bid="+bid+" Lots="+Lots);
break;
}
else
{
if (Trade=="Buy") Print("-----ERROR----- Placing BUY order: Lots="+Lots+" SL="+SL+" TP="+TP+" Bid="+bid+" Ask="+ask+" ticket="+ticket+" Err="+gle+" "+ErrorDescription(gle));
if (Trade=="Sell") Print("-----ERROR----- placing SELL order: Lots="+Lots+" SL="+SL+" TP="+TP+" Bid="+bid+" Ask="+ask+" ticket="+ticket+" Err="+gle+" "+ErrorDescription(gle));
RefreshRates();
Sleep(500);
// give up after 10 tries (~5 seconds)
loopcount++;
if(loopcount>10)
{
if (Trade=="Buy") Print("-----ERROR----- Giving up on placing BUY order");
if (Trade=="Sell") Print("-----ERROR----- Giving up on placing SELL order");
return(gle);
}
}
}
}
}
Thanks masta for the coding job.BTW yg aku punya camnilaa..edit2 bolehlaa..nak buat sebijik dari a-z..pening..huhuboleh edit ye