   [.net] TypeConverter's and C++/CLI.
  I have a C++ renderer wrapped in a C++/CLI which is linked into a C# scene editor. I want to display a drop down in the property grid which requires a custom type converter etc. The property tha this typeconverter will be used on is declared in a C++/CLI class. The scope of the typeconverter is unreachable i think from the C++/CLI so i can't add the attribute to the property there.The only way i can think to solve this is to wrap the C++/CLI class in another class in the scene editor that essentially forwards the attributes and then allows me to use the custom type editor.Is this the only reasonable solution?Thanks.   
Quote:Original post by DaveThe scope of the typeconverter is unreachable i think from the C++/CLI so i can't add the attribute to the property there.Could you clarify?;  The typeconverter class is declared in the C# project and that project depends directly on the C++/CLI project. The C++/CLI project contains the class that has the property for which i want to use the typeconverter i have created. This would require the C++/CLI project depending on the C# project.I can't declare the typeconverter in the C++/CLI project because it depends on some data stored in a ListBox component (which is used to populate the dropdown editor) that is owned by a class in the C# project. It's all rather complicated, but it could be me complicating things (probably the case)I have the typeconverter working correctly by wrapping the C++/CLI class with a C# class and mapping the properties through, however this is inelegant.Hope that clarifies.Thanks,   ;  Well, you can actually specify the fully qualified name of the type converter as a string in the attribute, and then let it all get hooked up at runtime. The type doesn't need to be accessible as long as Reflection and ComponentModel can get a hold of it and instantiate. So you can do [TypeConverter("Editor.Converters.MyConv")]. However, last time I tried this it had a habit of failing for no apparent reason, so...good luck. You might have to force the relevant types to be loaded or something.   ;  Ok, i'll give it a go, thanks alot.   ;  When you say it failed, did it fail silently? I am doing the following:[System::ComponentModel::TypeConverter("Editor.TextureConverter")]and it does nothing without warning about anything.   ;  Yeah, pretty much.   ;  Well that's a shame. Thanks anyways though =).   ;Quote:Original post by Dave[System::ComponentModel::TypeConverter("Editor.TextureConverter")]Because your type is defined in another assembly, you'll have to append the assembly name as well, like so:[System::ComponentModel::TypeConverter("Editor.TextureConverter, Editor.Assembly.Name")];Quote:Original post by CodekaQuote:Original post by Dave[System::ComponentModel::TypeConverter("Editor.TextureConverter")]Because your type is defined in another assembly, you'll have to append the assembly name as well, like so:[System::ComponentModel::TypeConverter("Editor.TextureConverter, Editor.Assembly.Name")]Can you give an example of what the Assembley.Name might be? Is it the name of the exe in the case of the C# project?   