0
我有CA1017错误消息与StyleCop说我需要使它ComVisible错误。CA1017与VS2010 ComVisible相关的错误StyleCop
Error 18 CA1017 : Microsoft.Design :
Because 'NationalInstruments.Labview.FPGA.ModelsimCommunicator.dll' exposes externally
visible types, mark it with ComVisible(false) at the assembly level and then mark all
types within the assembly that should be exposed to COM clients with ComVisible(true).
然后,我把代码[assembly: ComVisible(false)]
放在最顶层的命名空间之前。但是,我仍然遇到了与其他错误消息一样的错误。
Error 19 The type or namespace name 'ComVisible' could not be found (are you
missing a using directive or an assembly reference?)
Error 20 The type or namespace name 'ComVisibleAttribute' could not be found (are
you missing a using directive or an assembly reference?)
看来VS2010也不认识这个名字。
这有什么错呢?