Ask! - page 70 1...636465666768697071727374757677...182 New comment iscuba11 2007.08.02 04:28 #691 Thanks, I think I can take it from here with your coding. As they say in the South, Moucho Gracias! Dave <<< fxbeginner 2007.08.02 07:36 #692 Codersguru please help me! Hello. Perhaps you can help me. I try to code EA with Ichimoku a Kinko Hyo. It is to set a Buy order, if the Tenkan - sen is over the Kijun - sen. If Tenkan<Kijun then Sell order. And whole at 20.00 o'clock. Please help me. Thank you. fxbeginner Indicators with alerts/signal Set stop loss on when Tenkan-sen and Kijun-sen european 2007.08.02 07:45 #693 entry on a new bar I am coding an option of OrderSend on the start of the next bar. Anybody can direct/post good code on how to enter trade on a new bar? luckyfx 2007.08.02 09:08 #694 not trade on Monday Hello! Could someone post simple code which disable Expert on Monday and start trading week only of the beginning of Tuesday? Thanks! luckyfx flexie 2007.08.02 09:18 #695 european:I am coding an option of OrderSend on the start of the next bar. Anybody can direct/post good code on how to enter trade on a new bar? // in main program if(NewBar()) doEnterTrade(); bool NewBar() { static datetime dt = 0; if (Time[0] != dt) { dt = Time[0]; return(true); } return(false); } Mark flexie 2007.08.02 09:21 #696 luckyfx:Hello! Could someone post simple code which disable Expert on Monday and start trading week only of the beginning of Tuesday? Thanks! luckyfx #define TUESDAY 2 if(DayOfWeek() < TUESDAY) return(0); Mark european 2007.08.02 10:37 #697 flexie:// in main program if(NewBar()) doEnterTrade(); bool NewBar() { static datetime dt = 0; if (Time[0] != dt) { dt = Time[0]; return(true); } return(false); } Mark Thanks flexie, I know how to use Time/iTime now. euro Benjimang 2007.08.02 11:14 #698 Benjimang:Hi everyone! I have used the Expert Advisor Builder at sufx.com to create an EA. It has two limitations that I am trying to get rid of: 1. only opens 1 trade at a time. I can get it to have two trades open at once, but I can't get it to open a buy order and a sell order simultaneously. 2. seems to take sell orders as a preference over buy orders. This wouldn't really be an issue if problem number 1 was solved. Here is the peice of code that seems to be holding me up: //Check position bool IsTrade = False; for (int i = 0; i < Total; i ++) { OrderSelect(i, SELECT_BY_POS, MODE_TRADES); if (OrderType() <= OP_SELL && OrderSymbol() == Symbol()) { IsTrade = True; if (OrderType() == OP_BUY) { //Close Any suggestions? I'd like to let it open as many trades as possible, and be able to open buy and sell orders simultaneously if the indicators say so. Cheers for the help, Benjimang Why is everyone ignoring me? luckyfx 2007.08.02 11:22 #699 flexie:#define TUESDAY 2 if(DayOfWeek() < TUESDAY) return(0); Mark To flexie: Thanks a lot! It works fine! SaxMan 2007.08.02 21:25 #700 New Question -- Simple and quick for "Pros" Hi Coders, I need a simple code function to look back over a certain number of bars and return the index of the bar with the greatest range (i.e. high[]-low[]) as well as the range of that bar, itself. Any help would be appreciated, Thanks, SaxMan Simple & Quick Programming Custom Chart Timeframes -- Can a function return 1...636465666768697071727374757677...182 New comment
Thanks, I think I can take it from here with your coding. As they say in the South, Moucho Gracias!
Codersguru please help me!
Hello. Perhaps you can help me.
I try to code EA with Ichimoku a Kinko Hyo.
It is to set a Buy order, if the Tenkan - sen is over the Kijun - sen.
If Tenkan<Kijun then Sell order. And whole at 20.00 o'clock.
Please help me.
Thank you.
fxbeginner
entry on a new bar
I am coding an option of OrderSend on the start of the next bar.
Anybody can direct/post good code on how to enter trade on a new bar?
not trade on Monday
Hello!
Could someone post simple code which disable Expert on Monday and start trading week only of the beginning of Tuesday?
Thanks!
luckyfx
I am coding an option of OrderSend on the start of the next bar. Anybody can direct/post good code on how to enter trade on a new bar?
// in main program
if(NewBar()) doEnterTrade();
bool NewBar()
{
static datetime dt = 0;
if (Time[0] != dt)
{
dt = Time[0];
return(true);
}
return(false);
}
Mark
Hello!
Could someone post simple code which disable Expert on Monday and start trading week only of the beginning of Tuesday?
Thanks!
luckyfx#define TUESDAY 2
if(DayOfWeek() < TUESDAY) return(0);
Mark
// in main program
if(NewBar()) doEnterTrade();
bool NewBar()
{
static datetime dt = 0;
if (Time[0] != dt)
{
dt = Time[0];
return(true);
}
return(false);
}
MarkThanks flexie,
I know how to use Time/iTime now.
euro
Hi everyone!
I have used the Expert Advisor Builder at sufx.com to create an EA. It has two limitations that I am trying to get rid of:
1. only opens 1 trade at a time. I can get it to have two trades open at once, but I can't get it to open a buy order and a sell order simultaneously.
2. seems to take sell orders as a preference over buy orders. This wouldn't really be an issue if problem number 1 was solved.
Here is the peice of code that seems to be holding me up:
bool IsTrade = False;
for (int i = 0; i < Total; i ++) {
OrderSelect(i, SELECT_BY_POS, MODE_TRADES);
if (OrderType() <= OP_SELL && OrderSymbol() == Symbol()) {
IsTrade = True;
if (OrderType() == OP_BUY) {
//CloseAny suggestions? I'd like to let it open as many trades as possible, and be able to open buy and sell orders simultaneously if the indicators say so.
Cheers for the help,
BenjimangWhy is everyone ignoring me?
#define TUESDAY 2
if(DayOfWeek() < TUESDAY) return(0);
MarkTo flexie:
Thanks a lot! It works fine!
New Question -- Simple and quick for "Pros"
Hi Coders,
I need a simple code function to look back over a certain number of bars and return the index of the bar with the greatest range (i.e. high[]-low[]) as well as the range of that bar, itself.
Any help would be appreciated,
Thanks,
SaxMan