"is it possible to supply a type converter for a static resource in wpf?" Code Answer

5

it is possible if you use a binding. it seems a little weird, but this will actually work:

<textblock text="{binding source={staticresource today}}" />

it is because the binding engine has built-in type conversion for the basic types. also, by using the binding, if a built-in converter doesn't exist, you can specify your own.

By Yusuke Kawanabe on July 2 2022

Answers related to “is it possible to supply a type converter for a static resource in wpf?”

Only authorized users can answer the Search term. Please sign in first, or register a free account.