If the last character in the string passed by SetLabel() or in the constructor is & (ampersand) then Python immediately exits. I guess because it is trying to set the non-existent following character as a keyboard shortcut. I haven’t made a runnable sample but the situation can easily be created in the Static Text (Core Windows/Controls) demo. If someone can confirm it, I will raise a ticket.
The work around is to use SetLabelText() which doesn’t afford & any special treatment.
It sounds an unlikely scenario I know, but it did happen. A customer entered a recipe name as “Egg-White Omelette with Asparagus &”, presumably in error, but & what, we will never know
If the last character in the string passed by SetLabel() or in the
constructor is & (ampersand) then Python immediately exits. I guess
because it is trying to set the non-existent following character as a
keyboard shortcut. I haven't made a runnable sample but the situation
can easily be created in the Static Text (Core Windows/Controls) demo.
If someone can confirm it, I will raise a ticket.
Go ahead and create the ticket, I've confirmed it. Here is a backtrace that you can include: