For design-time translation support in my app I had the idea of loading the XML files (and thus parsing the data) at design-time via a new AppDomain (sandbox) so the assemblies wouldn't lock (which breaks the build process).
The problem is: I have two libraries containing language files in my application directory and two more which are in a sub-folder called "Modules". I can load the two in the app directory into the AppDomain but once I try to load the modules it fires an FileNotFoundException
.
Setting the AssemblyResolve
event does not work (fires an exception which states that the class is not marked as serializable). Setting ApplicationBase
and PrivateBinPath
does not work either (throws an exception saying that some Visual Studio components could not be found).
There is simply no way to do this without loading them directly which results in the designer process locking the assemblies.
Is there no easy way to simply load a resource from an assembly witout keeping it loaded (from the XAML designer process in this case)?
Aucun commentaire:
Enregistrer un commentaire