Download MetaTrader 5

Items of the ComboBox are not displayed.

To add comments, please log in or register
Hello community,

I got stuck on a problem with the ComboBox from the standard library.

After successful creation with the "Create" method I intended to add some items with the "ItemAdd" method. Finally the ComboBox is added to a CDialog. The source is as follows:

   int y2=y1+EDIT_HEIGHT;

      for(int t=0; t<16; t++)
         TradingDialogTradesComboBox.ItemAdd("Test Item "+IntegerToString(t),t);


As mentioned, the ComboBox is created without any error. The "Items" are created without any errors. The addition of the ComboBox to the CDialog is done without any problems. But when I click the "Button" of the ComboBox to extract the menu, any of the Items is displayed despite of the fact that they are listed in the ObjectList of the Terminal. The attempt to edit these Items manually shows, that they are not visualized. See:

Items not visible

I kindly ask you for your help and clues, because in this case I have no idea where to start to eliminate the cause.

In addition, I checked the Controls.mq5 Example which is working fine on the other hand. See:

The Controls.mq5 Example

This makes me even more clueless.


Olle Onkel

To add comments, please log in or register