这是在重新托管的设计器中... 如果我声明类型为List< MyNamespace.MyClass>的变量MyList,并尝试将默认值设置为New List(Of MyNamespace.MyClass )()我收到一个验证错误:在处理表达式'New List(Of MyNamespace.MyClass)()'时遇到编译器错误.类型'MyClass'未定义. 如果尝试将变量绑定到Activites OutArgument< List< MyClass>> ;,也会遇到相同的错误. 这是一个错误吗?
This is in a rehosted designer...If I declare a variable MyList of typeList<MyNamespace.MyClass>, and try to set the default value to New List(Of MyNamespace.MyClass)() i get a validation error:"Compiler error encountered processing expression 'New List(Of MyNamespace.MyClass)()'. Type'MyClass' is not defined." I get this same error if I try to bind the varable to an Activites OutArgument<List<MyClass>>.Is this a bug?
推荐答案
您好,您可以打开Imports设计器并查看MyNamespace是否存在导入吗?如果不是,那么您需要在执行操作之前显式添加导入(编译器使用序列化的名称空间/程序集对进行名称解析). 谢谢
Hi, can youopen the Imports designer and see if there is an import for MyNamespace? If not, then you need to explicitly add the import before you can proceed (the compiler uses a serialized namespace/assembly pair for name resolution). Thanks
更多推荐
类型列表< MyClass>的变量;不会接受默认值或绑定到OutArgument< List< MyCl
发布评论