Questions pour les débutants sur le Moxx - page 15

 
prostotrader:

et que dois-je faire à ce sujet ?

 
Вадим Мотеюнас:

et qu'est-ce que je suis censé faire à ce sujet ?

Qu'est-ce que tu fais, tu fais du commerce avec tes mains ?

 
prostotrader:

Qu'est-ce que vous faites, vous échangez des mains ?

Oui

 
Вадим Мотеюнас:

oui

Esquissez cet EA sur un graphique commercial (voir fichiers).

//+------------------------------------------------------------------+
//|                                                    Pos_price.mq5 |
//|                                      Copyright 2018 prostotrader |
//|                                             https://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2018 prostotrader"
#property link      "https://www.mql5.com"
#property version   "1.00"
//---
double pos_price;
//+------------------------------------------------------------------+
//| Expert Get position price function                               |
//+------------------------------------------------------------------+
double GetPositionPrice(const string aSymbol)
  {
   double price_in=0;
   double volume_in=0;
   if(PositionSelect(aSymbol))
     {
      ulong pos_id=ulong(PositionGetInteger(POSITION_IDENTIFIER));
      if(pos_id>0)
        {
         if(HistorySelectByPosition(pos_id))
           {
            int deals = HistoryDealsTotal();
            for(int i = 0; i < deals; i++)
              {
               ulong deal_ticket=HistoryDealGetTicket(i);
               ulong order_ticket=ulong(HistoryDealGetInteger(deal_ticket,DEAL_ORDER));
               if(order_ticket>0)
                 {
                  ENUM_DEAL_ENTRY deal_entry=ENUM_DEAL_ENTRY(HistoryDealGetInteger(deal_ticket,DEAL_ENTRY));
                  if(deal_entry==DEAL_ENTRY_IN)
                    {
                     double price=HistoryDealGetDouble(deal_ticket,DEAL_PRICE);
                     double volume=HistoryDealGetDouble(deal_ticket,DEAL_VOLUME);
                     price_in+=price*volume;
                     volume_in+=volume;
                    }
                 }
              }
            if(volume_in>0)
              {
               int digits=int(SymbolInfoInteger(aSymbol,SYMBOL_DIGITS));
               return(NormalizeDouble(price_in/volume_in, digits));
              }
           }
         else
           {
            Print(__FUNCTION__,": Невозможно получить историю позиции по символу ",aSymbol);
           }
        }
      else
        {
         Print(__FUNCTION__,": Невозможно определить идентификатор позиции по символу ",aSymbol);
        }
     }
   return(0);
  }
//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
int OnInit()
  {
   pos_price=GetPositionPrice(Symbol());
   ObjectCreate(ChartID(),"Pos_price_1",OBJ_LABEL,0,0,0);
   ObjectSetInteger(ChartID(),"Pos_price_1",OBJPROP_XDISTANCE,5);
   ObjectSetInteger(ChartID(),"Pos_price_1",OBJPROP_YDISTANCE,15);
//---
   ObjectSetInteger(ChartID(),"Pos_price_1",OBJPROP_COLOR,clrWhite);
   ObjectSetString(ChartID(),"Pos_price_1",OBJPROP_TEXT,"Цена позиции: "+DoubleToString(pos_price));
   ChartRedraw(ChartID());
   return(INIT_SUCCEEDED);
  }
//+------------------------------------------------------------------+
//| Expert deinitialization function                                 |
//+------------------------------------------------------------------+
void OnDeinit(const int reason)
  {
   ObjectDelete(ChartID(),"Pos_price_1_1");
  }
//+------------------------------------------------------------------+
//| Expert tick function                                             |
//+------------------------------------------------------------------+
void OnTick()
  {
   pos_price=GetPositionPrice(Symbol());
   ObjectSetString(ChartID(),"Pos_price_1",OBJPROP_TEXT,"Цена позиции: "+DoubleToString(pos_price));
   ChartRedraw(ChartID());
  }
//+------------------------------------------------------------------+

Ajouté

Mise à jour de l'EA (affichage immédiat du prix de la position )

 
prostotrader:

Esquissez cet EA sur le graphique commercial (voir fichiers).

Ajouté

Obnoyil EA (montre le prix de la position instantanément)

je pense que je vous ai mal compris ou peut-être que je vous ai mal compris, je voulais que la déclaration dans mt5 coïncide avec le suivi sur ***.

 
Вадим Мотеюнас:

Vous avez dû mal comprendre, ou je vous ai mal compris, je voulais que la déclaration dans mt5 coïncide avec le suivi sur ***.

Et je pensais que vous vouliez le vrai prix de la position, pas un ajustement de quelque chose à quelque chose...

Ajouté

Ni MT5 ni*** ne calculent correctement le prix de la position, car la compensation dans MT5 est prise en compte, et***on ne sait pas ce qu'elle compte.

 
prostotrader:

Et je pensais que vous vouliez le vrai prix de la position, pas un ajustement de quelque chose à quelque chose...

Ajouté

Je ne sais pas ce qui calcule correctement le prix d'une position car MT5 prend en compte la compensation dans MT5 et je ne sais pas ce qui la calcule du tout dans ***.

je ne sais pas s'il existe un bon service gratuit de statistiques pour mt5 et forts ?

 
Вадим Мотеюнас:

existe-t-il de bons services de statistiques gratuits pour mt5 et forts ?

Comment ne pas aimer ce qui est gratuit de ma part ?

Compte immédiatement les bénéfices réels

//+------------------------------------------------------------------+
//|                                                    Pos_price.mq5 |
//|                                      Copyright 2018 prostotrader |
//|                                             https://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2018 prostotrader"
#property link      "https://www.mql5.com"
#property version   "1.00"
//---
double pos_price, profit;
ENUM_POSITION_TYPE pos_type;
//+------------------------------------------------------------------+
//| Expert Get position price function                               |
//+------------------------------------------------------------------+
double GetPositionPrice(const string aSymbol)
  {
   double price_in=0;
   double volume_in=0;
   if(PositionSelect(aSymbol))
     {
      ulong pos_id=ulong(PositionGetInteger(POSITION_IDENTIFIER));
      if(pos_id>0)
        {
         if(HistorySelectByPosition(pos_id))
           {
            int deals = HistoryDealsTotal();
            for(int i = 0; i < deals; i++)
              {
               ulong deal_ticket=HistoryDealGetTicket(i);
               ulong order_ticket=ulong(HistoryDealGetInteger(deal_ticket,DEAL_ORDER));
               if(order_ticket>0)
                 {
                  ENUM_DEAL_ENTRY deal_entry=ENUM_DEAL_ENTRY(HistoryDealGetInteger(deal_ticket,DEAL_ENTRY));
                  if(deal_entry==DEAL_ENTRY_IN)
                    {
                     double price=HistoryDealGetDouble(deal_ticket,DEAL_PRICE);
                     double volume=HistoryDealGetDouble(deal_ticket,DEAL_VOLUME);
                     price_in+=price*volume;
                     volume_in+=volume;
                    }
                 }
              }
            if(volume_in>0)
              {
               int digits=int(SymbolInfoInteger(aSymbol,SYMBOL_DIGITS));
               return(NormalizeDouble(price_in/volume_in, digits));
              }
           }
         else
           {
            Print(__FUNCTION__,": Невозможно получить историю позиции по символу ",aSymbol);
           }
        }
      else
        {
         Print(__FUNCTION__,": Невозможно определить идентификатор позиции по символу ",aSymbol);
        }
     }
   return(0);
  }
//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
int OnInit()
  {
   ObjectCreate(ChartID(),"Pos_price_1",OBJ_LABEL,0,0,0);
   ObjectCreate(ChartID(),"Pos_price_2",OBJ_LABEL,0,0,0);
   ObjectSetInteger(ChartID(),"Pos_price_1",OBJPROP_XDISTANCE,5);
   ObjectSetInteger(ChartID(),"Pos_price_2",OBJPROP_XDISTANCE,5);
   ObjectSetInteger(ChartID(),"Pos_price_1",OBJPROP_YDISTANCE,15);
   ObjectSetInteger(ChartID(),"Pos_price_2",OBJPROP_YDISTANCE,30);
//---
   ObjectSetInteger(ChartID(),"Pos_price_1",OBJPROP_COLOR,clrWhite);
   ObjectSetInteger(ChartID(),"Pos_price_2",OBJPROP_COLOR,clrWhite);
   if(PositionSelect(Symbol()))
   {
     pos_type = ENUM_POSITION_TYPE(PositionGetInteger(POSITION_TYPE));
     pos_price=GetPositionPrice(Symbol());
     switch(pos_type)
     {
       case POSITION_TYPE_SELL:
         profit = pos_price - SymbolInfoDouble(Symbol(), SYMBOL_LAST);
       break;
       case POSITION_TYPE_BUY:
       profit = SymbolInfoDouble(Symbol(), SYMBOL_LAST) - pos_price;
       break;
     }
     ObjectSetString(ChartID(),"Pos_price_1",OBJPROP_TEXT,"Цена позиции: " + DoubleToString(pos_price));
     ObjectSetString(ChartID(),"Pos_price_2",OBJPROP_TEXT,"Текущий профит: " + DoubleToString(profit));
   }
   else
   {
     ObjectSetString(ChartID(),"Pos_price_1",OBJPROP_TEXT,"Цена позиции: 0");
     ObjectSetString(ChartID(),"Pos_price_2",OBJPROP_TEXT,"Текущий профит: 0");
   }  
   ChartRedraw(ChartID());
   return(INIT_SUCCEEDED);
  }
//+------------------------------------------------------------------+
//| Expert deinitialization function                                 |
//+------------------------------------------------------------------+
void OnDeinit(const int reason)
  {
   ObjectDelete(ChartID(),"Pos_price_1");
   ObjectDelete(ChartID(),"Pos_price_2");
  }
//+------------------------------------------------------------------+
//| Expert tick function                                             |
//+------------------------------------------------------------------+
void OnTick()
  {
   if(PositionSelect(Symbol()))
   {
     pos_type = ENUM_POSITION_TYPE(PositionGetInteger(POSITION_TYPE));
     pos_price=GetPositionPrice(Symbol());
     switch(pos_type)
     {
       case POSITION_TYPE_SELL:
         profit = pos_price - SymbolInfoDouble(Symbol(), SYMBOL_LAST);
       break;
       case POSITION_TYPE_BUY:
       profit = SymbolInfoDouble(Symbol(), SYMBOL_LAST) - pos_price;
       break;
     }
     ObjectSetString(ChartID(),"Pos_price_1",OBJPROP_TEXT,"Цена позиции: " + DoubleToString(pos_price));
     ObjectSetString(ChartID(),"Pos_price_2",OBJPROP_TEXT,"Текущий профит: " + DoubleToString(profit));
   }
   else
   {
     ObjectSetString(ChartID(),"Pos_price_1",OBJPROP_TEXT,"Цена позиции: 0");
     ObjectSetString(ChartID(),"Pos_price_2",OBJPROP_TEXT,"Текущий профит: 0");
   }
   ChartRedraw(ChartID());
  }
//+------------------------------------------------------------------+
 
prostotrader:

Qu'est-ce que tu n'aimes pas dans mon parasitisme ?

J'ai besoin de quelque chose comme un journal des transactions avec le renouvellement automatique de l'historique des transactions, pour analyser les statistiques de mon commerce, sur le forex *** à travers mt4 fonctionne et compte tout correctement (au moins l'état de mt4 coïncide avec les chiffres ***). connecté le compte de forts chiffres différents ... alors j'ai demandé. Je pensais que peut-être dans mt5 besoin de quelque chose à hacker

Пользовательский интерфейс - Начало работы - MetaTrader 5
Пользовательский интерфейс - Начало работы - MetaTrader 5
  • www.metatrader5.com
Интерфейс платформы предоставляет доступ ко всем инструментам, необходимым для торговли на финансовых рынках. Он включает в себя различные меню, панели инструментов и служебные окна. Главное меню В главном меню собраны практически все команды и функции, которые можно выполнять в торговой платформе. Оно позволяет работать с графиками...
 
Вадим Мотеюнас:

J'ai besoin d'une sorte de journal de transactions avec mise à jour automatique de l'historique des transactions pour analyser mes statistiques de trading, sur le forex ***mt4 fonctionne et compte correctement (au moins les statistiques de mt4 correspondent aux chiffres ***), j'ai connecté un compte de Forts les chiffres sont différents ... alors j'ai pensé que peut-être dans mt5 vous avez besoin de quelque chose à pirater

"Hack" n'a pas de sens, il faut juste

J'ai pensé qu'il fallait peut-être pirater quelque chose sur mt5.

Rédigez vos termes de référence et demandez ici

https://www.mql5.com/ru/job

Торговые приложения для MetaTrader 5 на заказ
Торговые приложения для MetaTrader 5 на заказ
  • www.mql5.com
1. мы задаём период(например неделя вперёд или сутки), которые сразу же разрисовываются полосками временных периодов по нашему желанию от м5 и до W1(с стандартным выбором цветов, толщин линий, пунктиров и т.п.) как в любом индикаторе. Добавление этих полос по выбору- можем хоть 2 , хоть все добавить. И присвоить им цвет, тип , толщину и т.п. А...
Raison: