Just enter Regedit.exe and create the key in the same way as:
HKLM \ SOFTWARE \ Microsoft \ .NETFramework \ v2.0.50727 \ AssemblyFoldersEx \ StackOverflow
It doesn't really matter what the key name is; all the folder names listed in AssemblyFoldersEx are looked up for the build time of the Visual Studio assembly.
The folder should be added to Regedit using the entry (default) that has the path to the folder as the value. (See, for example, words for sibling).
Interestingly, all folders present in the AssemblyFoldersEx registry key will also automatically appear when you click "Add New Link" in the project’s context menu on the .NET tab.
Another approach would be to add the desired assembly to the global access cache (c: \ Windows \ Assembly)
I just did the following test: On the resource assembly, I put the following code:
public class MyEditor : UITypeEditor { public override UITypeEditorEditStyle GetEditStyle(System.ComponentModel.ITypeDescriptorContext context) { return UITypeEditorEditStyle.Modal; } public override object EditValue(System.ComponentModel.ITypeDescriptorContext context, IServiceProvider provider, object value) { MessageBox.Show("Works"); return null; } }
In the consumer assembly (building Windows executables), I created a component that comes from Button just like this:
public class MyButton : Button { [Editor("AssemblyReferenceCL.MyEditor, AssemblyReferenceCL", typeof(UITypeEditor))] public String MyProp { get; set; } }
There is no link between the two assemblies. Everything worked fine.
source share