My first approach was to attach a handler that is called when there are exceptions in loading a certain assembly. The idea would then have been to modify the path of the assembly such that it points to a folder "dependencies" on my application where all the needed 3rd-party dlls are deployed.
AppDomain.CurrentDomain.AssemblyResolve += new ResolveEventHandler(CurrentDomain_AssemblyResolve);This seemed to work initially but sadly I got exceptions from the "Presentation.Zune.dll" which I was then not able to handle properly. So thanks to the guys at StackOverflow.com this is the final working solution. Put the following code in your App.config:
System.Reflection.Assembly CurrentDomain_AssemblyResolve(object sender, ResolveEventArgs args)
//find the path to the assembly and then load and return it by
<configuration>"dependencies" is the folder on the application directory where the 3rd-party dlls can be found.