BuildApp – AssembliesLoader

The given assemblies are loaded to the current AppDomain, if necessary:

Assembly[] tAssembliesOfDomain = AppDomain.CurrentDomain.GetAssemblies();

foreach (FileInfo tFile in app.AssembliesToLoad) {

	bool tLoadAssembly = true;
 
	foreach (Assembly tAssemblyOfCurrentDomain in tAssembliesOfDomain){
					
		if (tAssemblyOfCurrentDomain.Location == tFile.FullName)
			tLoadAssembly = false;
	} 
	if (tLoadAssembly) {
		try {
			Assembly tComponent = Assembly.LoadFrom(tFile.FullName);
			...
		}
		Catch …
	}
}

Last edited Apr 20, 2013 at 9:43 AM by InneHo, version 3

Comments

No comments yet.