Char& amp;行为控制

Char & behaviour on controls

Currerently I face strange behaviour on my controls when text is present either on advlistbox items or buttonx and probably rest as well. This happens when i use & charackter within string. For instance when i use double && it shows single one. Another example when i put e.g &&&something then it shows &something with s - underscored. Is there anyone whom knows what is going on and how can i avoid that situation?

A double ampersand is used to escape the default behavior of an ampersand relative to controls. When an ampersand precedes control text it underlines the following character, usually to denote that controls hotkey. In the case of your triple ampersand situation you are using the right most ampersand as the underline and the remaining 2 as an escape so that a literal ampersand is displayed in your controls text.

If your goal is to literally display 2 ampersands then you must supply your control text with a total of 4 consecutive ampersands. (&&&&)

i found one solution to false this property UseMnemonic which is available for buttonx but i cannot see it for advlistbox
@JimmyJimm You could extend the listbox control and apply the property yourself
can you provide some solution how can i do this best way as i have 'thousand of places' where i would have to do that replacment,
so what should i do in case i have in db this one: Betten & Liegen but in advlistbox i see: Betten _Liegen or in db i have Eck- & Sitzbänke and in advlistbox i see: Eck-_Sitzbänke . Can you tell me how can i fix that situation or what to do? My client require to use it. Please dont tell me to everytime check what's in database and then convert it to the proper form this would be very annoying especially if probably i cannot imagine all user behaviours and will.
@JimmyJimm If you want an ampersand to appear in your controls text then you must provide it with 2 (&&)