我在Visual Studio中有以下两个文件:
//file1.cs
using System;
namespace Pointns{
public class Point{
public float x;
public float y;
public Point(){
x = 0;
y = 0;
}
}
}
//file2.cs
using System;
using Pointns;
namespace test1{
class test2{
static void Main(){
Point p1 = new Point();
Console.WriteLine("Hello World");
Console.WriteLine(p1.x);
Console.ReadLine();
}
}
}
当我尝试编译时,它说找不到Pointns
。我做错了什么?
答案 0 :(得分:0)
您应该考虑以下事项: