cabo
June 6th, 2009, 06:24 AM
Hello all,
its my first day on C#.
I'm trying to use namespaces but its not working.
I'm trying to call a method in namespace namespaceTest.test1 with
testing test = new testing1();. I get this message: The type or namespace could not be found.
Any idea how to edit that line so that i can use the method in namespace namespaceTest.test1
// The C# Station Namespace
namespace namespaceTest
{
namespace namespaceTest.test1
{
// Program start class
class testing1
{
// Main begins program execution.
public int test()
{
Console.WriteLine("This is the new C# Station Namespace 2.");
return 10;
}
}
}
namespace namespaceTest.test2
{
using namespaceTest.test1;
// Program start class
class testing2
{
// Main begins program execution.
public void test()
{
testing test = new testing1();
Console.WriteLine("This is the new C# Station Namespace 2.");
}
}
}
}
its my first day on C#.
I'm trying to use namespaces but its not working.
I'm trying to call a method in namespace namespaceTest.test1 with
testing test = new testing1();. I get this message: The type or namespace could not be found.
Any idea how to edit that line so that i can use the method in namespace namespaceTest.test1
// The C# Station Namespace
namespace namespaceTest
{
namespace namespaceTest.test1
{
// Program start class
class testing1
{
// Main begins program execution.
public int test()
{
Console.WriteLine("This is the new C# Station Namespace 2.");
return 10;
}
}
}
namespace namespaceTest.test2
{
using namespaceTest.test1;
// Program start class
class testing2
{
// Main begins program execution.
public void test()
{
testing test = new testing1();
Console.WriteLine("This is the new C# Station Namespace 2.");
}
}
}
}