Shared Service for Resources

Jan 24, 2013 at 7:24 AM

Hi List,

i'm working on an Shared Service to have all of my resources in the Shell-Project and access them with a Shared Service.

What i'm found so far ist:

                <ResourceDictionary Source="pack://application:,,,/Resources/Icons/VistaIcons/Edit.xaml"/>
                <ResourceDictionary Source="pack://application:,,,/Resources/Icons/VistaIcons/Add.xaml"/>
                <ResourceDictionary Source="pack://application:,,,/Resources/Icons/VistaIcons/Delete.xaml"/>
                <ResourceDictionary Source="pack://application:,,,/Resources/Icons/VistaIcons/Save.xaml"/>
                <ResourceDictionary Source="pack://application:,,,/Resources/Icons/VistaIcons/Save_All.xaml"/>

But this will be very uncomfortable with lot's of Icons.

Is there any better idea.




Jan 24, 2013 at 2:18 PM

Hi Peter,

In my opinion if you have several resources that need to be loaded from one assembly, I believe you could consider having a resource dictionary in that assembly that uses MergedDictionaries to reference all the related ResourceDictionary (e.g Edit.xaml, Add.xaml ...). This way in the application consuming this assembly you could reduce the number of resource dictionaries you will have to define.

Also, regarding this topic I believe you could check the following thread where a similar discussion is addressed:

I hope you find this helpful,

Agustin Adami

Jan 25, 2013 at 7:07 AM


that's exactly what i'm looking for