how to create object for Nested Class in c#

Gow.Net
Posted by Gow.Net under C# category on | Points: 40 | Views : 3658
 public class Aclass
{
public Aclass()
{
Console.WriteLine("Aclass");
}
public class Bclass //second class
{

public Bclass()
{
Console.WriteLine("Bclass");
}
}
}
class Program
{
static void Main(string[] args)
{
Aclass objAclass = new Aclass();//objcet create for Aclass
Aclass.Bclass objBclass = new Aclass.Bclass();//objcet create for Bclass (Nested Class)
}
}

Comments or Responses

Login to post response