Issue
Here's the code I have:
var LL = new Label()
{
HorizontalOptions = LayoutOptions.CenterAndExpand,
};
LL.SetDynamicResource(FontFamilyProperty, "Default-Medium");
I was trying to do it with the last line but it gives an error saying FontFamilyProperty does not exist.
Solution
You can use like this:
var LL = new Label()
{
HorizontalOptions = LayoutOptions.CenterAndExpand,
};
LL.SetDynamicResource(Label.FontFamilyProperty, "Default-Medium");
If you want to learn more than information for dynamic resources, you can look this documentation
Answered By - Pelin Konaray
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.