10. Sell Stop (Del)

Orders Execution
Checks for the total of open orders
Miscellaneous
It plays sound alertsIt issuies visual alerts to the screen
0 Views
0 Downloads
0 Favorites
10. Sell Stop (Del)
//+---------------------------------------------------------+
//         Ñêðèïò óáèð¸ò âñå Stll Stop ïî èíñòðóìåíòó       |
//+---------------------------------------------------------+
void start(){
PlaySound("tick.wav");
bool s = false;
int i=0;
for(;i<OrdersTotal();i++)
{//+---------------------------------------------------------------------+for
OrderSelect(i,SELECT_BY_POS);
 if(OrderSymbol()!= Symbol())continue;
 if(OrderType()!=5)continue;
 s=true;
 int Ticket = OrderTicket();
//+----------------------------------------------------------------------+
 OrderDelete(Ticket);
 int error = GetLastError();
 if(error==6){Alert("Íåò ñâÿçè");return;}
 if(error==132){Alert("Ðûíîê çàêðûò");return;}
   RefreshRates();
   i--;
 }//+--------------------------------------------------------------------+for
if(s)Alert("Îðäåðà Sell Stop óäàëåíû");else Alert("Íåò îðäåðîâ Sell Stop");
PlaySound("ok.wav");
 return;}

Comments

Markdown supported. Formatting help

Markdown Formatting Guide

Element Markdown Syntax
Heading # H1
## H2
### H3
Bold **bold text**
Italic *italicized text*
Link [title](https://www.example.com)
Image ![alt text](image.jpg)
Code `code`
Code Block ```
code block
```
Quote > blockquote
Unordered List - Item 1
- Item 2
Ordered List 1. First item
2. Second item
Horizontal Rule ---