testQuickReport

Orders Execution
It automatically opens orders when conditions are reached
0 Views
0 Downloads
0 Favorites
testQuickReport
ÿþ#include <MT4Orders.mqh>



//#define REPORT_BROWSER            // Open report in browswer automatically. Require DLL.

// By default MT4Orders_QuickReport use free google.charts, but you can use highcharts if you have rights.

// #define USE_highcharts // You can download and try out all Highcharts products for free. Once your project/product is ready for launch, purchase a commercial license. https://shop.highcharts.com/



#include <MT4Orders_QuickReport.mqh>



void OnInit(){}



void OnTick(){ strategy (); }



void OnDeinit(const int  reason ){

   QuickReport("report", true);

}



int TimeHour     ( datetime time ){return((int)((time / 3600) % 24));}//current hour in day. 3600 sec in hour



void strategy (){

  string Symb = _Symbol;

  MqlTick Tick;

  if (SymbolInfoTick(Symb, Tick)){    

    if(TimeHour(TimeCurrent())<23 && TimeHour(TimeCurrent())>0 ){return;} //A>25@H05< >?5@0F88 A 0 4> 1 8 A 23 4> 0

    OrderSend(Symb, OP_BUY,  10, Tick.ask, 0, Tick.bid, Tick.bid,  NULL, 1000);//"/! =0 3@0=8F5 A?@540 

    OrderSend(Symb, OP_SELL, 10, Tick.bid, 0, Tick.ask, Tick.ask,  NULL, 1000);//"/! =0 3@0=8F5 A?@540 

   }

}

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 ---