wpf - Resource Dictionary unable to catalog Converters -


i trying pull our converters common location @ top of application. when end following error:

sourcedefaultvalueconverter not supported in windows presentation foundation (wpf) project.

this app.xaml throwing error:

<application x:class="msms.datacollector.app.app"              xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"              xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"               xmlns:app="clr-namespace:app"              xmlns:commoncontrols="clr-namespace:commoncontrols;assembly=commoncontrols"              startupuri="loginwindow.xaml">     <application.resources>         <app:ninjectservicelocator x:key="servicelocator" />         <resourcedictionary x:key="resources">             <resourcedictionary.mergeddictionaries>                 <resourcedictionary source="resources/converters.xaml"/>             </resourcedictionary.mergeddictionaries>             <commoncontrols:fieldlayoutruntimecontrolconverter x:key="fieldlayoutconverter" />         </resourcedictionary>     </application.resources> </application> 

when add resource directly in usercontrol works correctly

<usercontrol.resources>     <commoncontrols:fieldlayoutruntimecontrolconverter x:key="fieldlayoutconverter"/> </usercontrol.resources> 

you have 1 resource (servicelocator) outside resourcedictionary. move alongisde fieldlayoutconverter resource. i'm not sure that's resulting in issue, it's wrong , may confusing wpf (which, alas, not hard do).


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -