Panel Developing

 
I am developing a trading panel for my study in MQL5.

Has anyone ever had a similar problem with this? The panel is created normally, but I have difficulties in being able to select the CEdit fields and also after clicking on a button the trading history overlays the panel
 
Hello, thank you for reaching out. This forum primarily operates in English, so it would be appreciated if you could kindly translate your Pic to English for everyone's understanding.
 
In fact, the pic is just to demonstrate that the negotiation history is in front of the panel
 
Set Chart to background. (F8>>Common>> Chart on foreground)
 

The Chart is already set as background, the panel is in front of everything on the chart, except the trading history.

When inserting the panel on the chart it is in front of everything, after sending an order the trading history is in front of it, even if the order is not sent by the panel.

I've already tried changing the z-Order, but it still doesn't work.

Look at this attached video, as I have difficulty clicking on a CEdit and as it keeps blinking, I now realized that if I change the chart to another asset the panel returns to the front of the trading history:
 

The laziest way is to place the panel on the right and use chart shift:


 

The second method is to re-create the panel. The object that was created most recently is displayed above all.

Perhaps there is another way that will avoid re-creation. I don't know.

 
If I'm not mistaken, I heard about the idea of changing the OBJPROP_TIMEFRAMES property instead of recreating the panel. Don't know if it works, I haven't tried it
 

First, thank you for everyone's attention

To create the panel I am using <Controls\Panel.mqh> Panel.Create

I did a GET on the panel's OBJPROP_TIMEFRAMES property and the return was "0", as if it was not in any graphical time.

This leads me to believe that the panel is not being created as a chart object, what do you think?

Vladislav Boyko
Vladislav Boyko
  • 2024.04.05
  • www.mql5.com
Trader's profile
 
CaioDicieri #:
I did a GET on the panel's OBJPROP_TIMEFRAMES property and the return was "0", as if it was not in any graphical time.

I've never used it. I just opened <Controls\Panel.mqh> for the first time and saw these methods:

//+------------------------------------------------------------------+
//| Display object on chart                                          |
//+------------------------------------------------------------------+
bool CPanel::OnShow(void)
  {
   return(m_rectangle.Timeframes(OBJ_ALL_PERIODS));
  }
//+------------------------------------------------------------------+
//| Hide object from chart                                           |
//+------------------------------------------------------------------+
bool CPanel::OnHide(void)
  {
   return(m_rectangle.Timeframes(OBJ_NO_PERIODS));
  }

The theory is that if you hide and then show an object, it will appear on top of all the others, as if it were created. But this is not certain, this needs to be checked😄

 
CaioDicieri #:
This leads me to believe that the panel is not being created as a chart object, what do you think?

Object List -> List all

See also OBJPROP_HIDDEN:

https://www.mql5.com/en/docs/constants/objectconstants/enum_object_property

OBJPROP_HIDDEN

Prohibit showing of the name of a graphical object in the list of objects from the terminal menu "Charts" - "Objects" - "List of objects". The true value allows to hide an object from the list. By default, true is set to the objects that display calendar events, trading history and to the objects created from MQL5 programs. To see such graphical objects and access their properties, click on the "All" button in the "List of objects" window.

bool