0
Views
0
Downloads
0
Favorites
MarketInfo
//+------------------------------------------------------------------+
//| BinuJoshep.mq4 |
//| Copyright © 2007, syanwar (www.viking234.com) |
//| admin@viking234.biz |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2007, syanwar (www.viking234.com)"
#property link "admin@viking234.biz"
#property indicator_chart_window
//+------------------------------------------------------------------+
//| Custom indicator initialization function |
//+------------------------------------------------------------------+
int init()
{
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator deinitialization function |
//+------------------------------------------------------------------+
int deinit()
{
//----
Comment("");
//----
return(0);
}
//+------------------------------------------------------------------+
//| Custom indicator iteration function |
//+------------------------------------------------------------------+
int start()
{
//---- indicators
double MPoint = MarketInfo(Symbol(), MODE_POINT); // Point size in the quote currency. For the current symbol, it is stored in the predefined variable Point
double MTickva = MarketInfo(Symbol(), MODE_TICKVALUE); // Tick value in the deposit currency.
double MTicksa = MarketInfo(Symbol(), MODE_TICKSIZE); // Tick size in points.
double MSpread = MarketInfo(Symbol(), MODE_SPREAD); // Spread value in points.
double MMinlot = MarketInfo(Symbol(), MODE_MINLOT); // Minimum permitted amount of a lot.
double MMaxlot = MarketInfo(Symbol(), MODE_MAXLOT); // Maximum permitted amount of a lot.
double MLotste = MarketInfo(Symbol(), MODE_LOTSTEP); // Step for changing lots.
double MStopLe = MarketInfo(Symbol(), MODE_STOPLEVEL); // Stop level in points.
double MLotsiz = MarketInfo(Symbol(), MODE_LOTSIZE); // Lot size in the base currency.
double MSwapty = MarketInfo(Symbol(), MODE_SWAPTYPE); // Swap calculation method. 0 - in points; 1 - in the symbol base currency; 2 - by interest; 3 - in the margin currency.
double MSwaplo = MarketInfo(Symbol(), MODE_SWAPLONG); // Swap of the long position.
double MSwapsh = MarketInfo(Symbol(), MODE_SWAPSHORT); // Swap of the short position.
double MStrati = MarketInfo(Symbol(), MODE_STARTING); // Market starting date (usually used for futures).
double MExpira = MarketInfo(Symbol(), MODE_EXPIRATION); // Market expiration date (usually used for futures).
double MTradea = MarketInfo(Symbol(), MODE_TRADEALLOWED); // Trade is allowed for the symbol.
double MProcal = MarketInfo(Symbol(), MODE_PROFITCALCMODE); // Profit calculation mode. 0 - Forex; 1 - CFD; 2 - Futures.
double MDigits = MarketInfo(Symbol(), MODE_DIGITS); // Count of digits after decimal point in the symbol prices. For the current symbol, it is stored in the predefined variable Digits
double MMarcal = MarketInfo(Symbol(), MODE_MARGINCALCMODE); // Margin calculation mode. 0 - Forex; 1 - CFD; 2 - Futures; 3 - CFD for indices.
double MMarini = MarketInfo(Symbol(), MODE_MARGININIT); // Initial margin requirements for 1 lot.
double MMarman = MarketInfo(Symbol(), MODE_MARGINMAINTENANCE); // Margin to maintain open positions calculated for 1 lot.
double MMarhed = MarketInfo(Symbol(), MODE_MARGINHEDGED); // Hedged margin calculated for 1 lot.
double MMarreq = MarketInfo(Symbol(), MODE_MARGINREQUIRED); // Free margin required to open 1 lot for buying.
double MFreezl = MarketInfo(Symbol(), MODE_FREEZELEVEL); // Order freeze level in points. If the execution price lies within the range defined by the freeze level, the order cannot be modified, cancelled or closed.
//----
Comment(
"ACCOUNT INFO\n- AccountLeverage: "+AccountLeverage()+
"\n- AccountNumber: "+AccountNumber()+
"\n- AccountName: "+AccountName()+
"\n- AccountCompany: "+AccountCompany()+
"\n- AccountServer: "+AccountServer()+
"\nMARKET INFO\n-= ", MPoint,
" (Point size in the quote currency. For the current symbol, it is stored in the predefined variable Point)\n-= ", MTickva,
" (Tick value in the deposit currency)\n-= ", MTicksa,
" (Tick size in points)\n-= ", MSpread,
" (Spread value in points)\n-= ", MMinlot,
" (Minimum permitted amount of a lot)\n-= ", MMaxlot,
" (Maximum permitted amount of a lot)\n-= ", MLotste,
" (Step for changing lots)\n-= ", MStopLe,
" (Stop level in points)\n-= ", MLotsiz,
" (Lot size in the base currency)\n-= ", MSwapty,
" (Swap calculation method. 0 - in points; 1 - in the symbol base currency; 2 - by interest; 3 - in the margin currency)\n-= ", MSwaplo,
" (Swap of the long position)\n-= ", MSwapsh,
" (Swap of the short position)\n-= ", MStrati,
" (Market starting date (usually used for futures))\n-= ", MExpira,
" (Market expiration date (usually used for futures))\n-= ", MTradea,
" (Trade is allowed for the symbol)\n-= ", MProcal,
" (Profit calculation mode. 0 - Forex; 1 - CFD; 2 - Futures)\n-= ", MDigits,
" (Count of digits after decimal point in the symbol prices. For the current symbol, it is stored in the predefined variable Digits)\n-= ", MMarcal,
" (Margin calculation mode. 0 - Forex; 1 - CFD; 2 - Futures; 3 - CFD for indices)\n-= ", MMarini,
" (Initial margin requirements for 1 lot)\n-= ", MMarman,
" (Margin to maintain open positions calculated for 1 lot)\n-= ", MMarhed,
" (Hedged margin calculated for 1 lot)\n-= ", MMarreq,
" (Free margin required to open 1 lot for buying)\n-= ", MFreezl,
" (Order freeze level in points. If the execution price lies within the range defined by the freeze level, the order cannot be modified, cancelled or closed)");//----
//----
return(0);
}
//+------------------------------------------------------------------+
Comments
Markdown Formatting Guide
# H1
## H2
### H3
**bold text**
*italicized text*
[title](https://www.example.com)

`code`
```
code block
```
> blockquote
- Item 1
- Item 2
1. First item
2. Second item
---