WebListBox bug


Here a problem when I just try to add a text containing the "=" symbol in a WebListBox, it's not displayed, nor is the rest of the text that follows.

  WebListBox1.AddItem('another=bug', nil); 

This is by design, the NameValueSeparator is an equal sign.
Please set the NameValueSeparator to something else to allow the usage of equal sign in item text

WebListBox1.Items.NameValueSeparator := '#';

I did consider this to be a bug, since a VCL TListBox does not behave in this way when adding a "name=value" item, and in your documentation the only mention we can read regarding this is :

A TWebListBox is a control having a list of (text) items, similar to a VCL TListBox.

Perhaps you could specify this in the documentation, or even add a published property NameValueSeparator to make things more obvious to everyone. (but then, of course, the control is not anymore exactly the same as in VCL)

thank you

We'll investigate this here. Thanks for the feedback.

1 Like

We will document this better. After all, a TWebListBox maps on a HTML SELECT elements so in a web environment, it is desirable to be able to take advantage of the name/value behavior that a HTML SELECT element offers.