Thread: what is asp.net
View Single Post
  #9 (permalink)  
Old May 3rd, 2007, 10:26 AM
Larryz Larryz is offline
Authorized User
 
Join Date: Apr 2007
Location: , , .
Posts: 28
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to Larryz
Default

So when you create a basic class,
For example
namespace mynamespace
{
public class myClass
{
 public string Name;
get
}
return name;
}
set
{

name = value;
}
public myClass()
{
//default constructor
}
public myClass(string objName)
{

}
}


here no methods have been defined, purposely....

Later we can try in console application....

class Program
{
static void Main(string[] args)
{
 myClass myObj = new myClass("Fred");
myClass.ToString();
// is possible because of inheritance ???????

}
}
}


}

Reply With Quote