引用命名空间: using System.Collections; 不行哈,ArrayList是System.Collections下的一个类型,而不是System.Collections.Generic下的,如果你不引用可以直接这么写: System.Collections.ArrayList = new System.Collections.ArrayList(arr); 上面得也是对的 用using System.Collections.Generic就没有把ArrayList这个类型引用进去
← 上一条:C#错误:未能找到类型或命名空间名称“Mes 下一条:请问什么是税收?具体对国家的用处在哪里? →