daniyalahmad
daniyalahmad

Reputation: 3843

How to set font size property by using applypropertyvalue

How to set font size by using applypropertyvalue in wpf

 ts.ApplyPropertyValue(TextElement.FontSizeProperty,new ?? );

Upvotes: 0

Views: 2313

Answers (1)

Viv
Viv

Reputation: 17380

Try:

ts.ApplyPropertyValue(TextElement.FontSizeProperty, (double)24);

or

ts.ApplyPropertyValue(TextElement.FontSizeProperty, 24.0);

Either approach should work fine.

Upvotes: 3

Related Questions