Alex Prinias asked 2016-07-31 12:44:33 UTC
Hi,
I'm trying to change the Fontstyle or Forecolor of a label at runtime based on a condition, something like:
lblCount.Font = new Font(lblCount.Font, (String.IsNullOrEmpty(_selCriteria) ? FontStyle.Regular : FontStyle.Bold));
but it doesn't work. Is this a bug, or there is another recommended way to do it?
Best,
Alex
Alex Prinias asked 2016-07-31 12:44:33 UTC
Hi,
I'm trying to change the Fontstyle or Forecolor of a label at runtime based on a condition, something like:
lblCount.Font = new Font(lblCount.Font, (String.IsNullOrEmpty(_selCriteria) ? FontStyle.Regular : FontStyle.Bold));
but it doesn't work. Is this a bug, or there is another recommended way to do it?
Best,
Alex