Custom symbols. Errors, bugs, questions, suggestions. - page 5

 
fxsaber:

However, for some reason it works.


I don't understand these lines:

    
  if (FirstRun)
  {
    Symb.DeleteHistory();       // Мало ли что-то было в истории - грохнули
    Symb.Delete(true);          // Символ тоже прибьем, чтобы исключить наличие тика в Обзоре рынка
    Symb.Create(NULL, _Symbol); // Воскресили девственно чистым.


Have you tried adding a single tick rather than a pack? And that the symbol is not selected in the marketwatch?

Have you tried adding a single bar on a newly created symbol, not a copied one. And that the instrument is not selected in the marketwatch?

Why would I need to open a chart

   ChartOpen(Symb.Name, PERIOD_M1); // Открыли чарт

I can have up to 1000 of these charts. I just need to save the history and if I need it I can open the actual chart.

 
Sergey Chalyshev:

Have you tried adding a single tick rather than a pack? And that the symbol is not selected in the marketwatch?

The@fxsaber code works, I've been using it for a long time, one tick is added without any problems, I have 4 online charts running, one Expert Advisor is processing (builds custom charts)

i do not understand the condition not to select the symbol in the market overview window - is this the main problem? - I did not look for a solution, but probably custom ticks are only thrown in this window

 
Igor Makanu:

code@fxsaber works, I use it for a long time, one tick is added without problems, I have online charts spinning - 4 pcs one Expert handles (builds custom charts)

i don't understand the condition of not selecting in the symbol in the market overview window - is this the main problem? - I was not looking for a solution, but probably custom ticks only in this window

One of the main ones.

Is it added to a symbol that is not selected and does not contain old bars?

It is not added to selected symbol if there is no chart opened (

 

For a start, what's wrong?

MqlTick tick;
MqlTick atick[];

int size=1000;
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart()
  {
//---
   string name="TestCastom";
   CustomSymbolCreate(name,"","EURGBP");

   ArrayResize(atick,1);
   while(!IsStopped())
     {
      SymbolInfoTick("EURGBP",tick);
      atick[0]=tick;
      if(CustomTicksAdd(name,atick)<=0) { Print("error CustomTicksAdd: ",GetLastError()); }
      Sleep(1000);
     }
  }
//+------------------------------------------------------------------+


The result:

2019.03.21 19:09:21.896 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:22.988 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:24.080 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:25.172 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:26.264 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:27.356 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:28.448 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:29.540 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:30.632 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
2019.03.21 19:09:31.724 CustomSymbolTest1 (EURGBP,M1)   error CustomTicksAdd: 4302
 
Sergey Chalyshev:

Even the selected symbol is not added if the chart is not open (

i checked, even when the chart is closed custom ticks are added

I've been using@fxsaber' s library for 6 months now, I don't have any problems

https://www.mql5.com/ru/forum/212096/page6#comment_9791450

Библиотеки: Symbol
Библиотеки: Symbol
  • 2018.10.30
  • www.mql5.com
Symbol: Автор: fxsaber...
 
Igor Makanu:

Checked it, even when the chart is closed custom ticks are added

I've been using@fxsaber' s library for 6 months now, I have not noticed any problems.

https://www.mql5.com/ru/forum/212096/page6#comment_9791450

I see that you haven't mastered thefxsaber library, and I don't want to either.

Try the example above.

 
Sergey Chalyshev:

I see you haven't dealt with thefxsaber library, and I don't want to either.

Try the example above.

I haven't dealt with@fxsaber library - it suits my needs and works like clockwork, alas, I don't have three lives to deal with everything, I tried it, it works, I made my own custom symbols - yes they work

i'm afraid i'm not an experienced user of MT5, i would have no problem mixing with MT4, while in MT5 i prefer to use a ready made solution, there are many features in MT5 that require either a detailed study or just using a ready made solution - this is my second choice

 
Igor Makanu:

I haven't dealt with@fxsaber library - it suits my needs and works like clockwork, alas, I don't have three lives to deal with everything, I tried it, it works, I made my own custom symbols - yes they work

I'm afraid I'm not an experienced user of MT5, I would have no problem with MT4, while with MT5 I prefer to use a ready-made solution, there are many features in MT5 that require either a detailed study or just using a ready-made solution - I have the second option

I am telling you, I don't have enough life to analyze other people's libraries.

I read the help and do what I need.

fxsaber is an amazing man, I am amazed at his efficiency.

It would be nice if he would connect to the problem of custom symbols, but he wouldn't mask the problems of MQL with his libraries.

 
Sergey Chalyshev:

fxsaber is an amazing man, I am amazed at his efficiency.

It would be nice if he would connect to the problem of custom characters, but not mask MQL problems with his libraries.

I don't think he's shy about reporting problems. And crutches have to be substituted. While the problems are being solved, we have to work somehow right now.

 
Edgar:

I don't think he's shy about reporting problems. And crutches have to be put up. While the problems are being solved, you have to work somehow right now.

What are you,fxsaber's lawyer? I don't think he needs a lawyer and can answer for himself.

I see you didn't use custom symbols.

Reason: