Hi everyone,
I'm having an issue that after days of tweaking continues to bother me. I have a VB application that has a ListView object, with a number of items whose fonts are set based on their priority to the user. The high priority items get bolded, and are meant to stay that way until the user activates them. The fonts are assigned at run-time, using the following type of code:
Dim fntFont As Font
fntFont = New Font(lvList.Font, lvList.Font.Style Or FontStyle.Bold)
...
lvListItem.Font = fntFont
This works fine on most machines, but on some new machines used by my company, a problem comes up. When the ListView loads, all items that are supposed to be bold are instead the default font of the ListView. When scrolling through the list, items that start off screen are correctly bolded, but as soon as they are highlighted, they reset to the default again. Both machines appear to be using the same version of the .NET framework, and there is nothing in the code that should cause this type of behaviour. Any ideas on what could be causing this? Any help is appreciated.