
06-06-2009, 03:09 AM
|
|
Member
|
|
Join Date: Dec 2008
Posts: 37
|
|
You can still hedge with a lot of brokers, my broker still allows hedging and could not care what robot you use or if you win or lose. Just shop around you will still find many brokers that you can hedge with!
Quote:
Originally Posted by ajk
Since hedging is not allowed anymore... does anyone have any trade ea manager or something that would reverse the trade immediately after close when a trade hits a stop loss...
or can any one show me how to add a pending order as a sell (below is a buy) so that it triggers as soon as sl is hit?
Thoughts?
ANy help appreciated!.
int OpenOrder(int type)
{
int ticket=0;
int err=0;
int c = 0;
if(type==OP_BUY)
{
for(c = 0 ; c < NumberOfTries ; c++)
{
ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,Slippage ,Ask-StopLoss*Point,Ask+TakeProfit*Point,ExpertComment, MagicNumber,0,Yellow);
err=GetLastError();
if(err==0)
{
break;
}
else
{
if(err==4 || err==137 ||err==146 || err==136) //Busy errors
{
Sleep(5000);
continue;
}
else //normal error
{
break;
}
}
}
}
|
|