Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is the purpose of new keyword while creating an object?

Answer Posted / noor mohammad

Types cannot be used without being instantiated. To
instantiate a type, you use the new operator, which invokes
the logic specified in the constructor. After completion,
the constructor returns a new instance of the specified
type—this instance can now store data as your C# program
executes.

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can fields inside a class be virtual?

1027


How do I create a .exe file?

1056


What is difference between constants and read-only?

1035


What happens if a static constructor throws an exception?

1000


What is meant by enumerable in c#?

1020


if a method is marked as protected internal who can access it?

1083


What is namespace give the example?

955


Which config file has all the supported channels/protocol?

1037


How does dependency injection work c#?

997


What is the main purpose of linq?

950


What is namespace explain with example?

916


What is difference between internal and protected internal in c#?

998


How do you serialize in c#?

922


Can constructor be protected in c#?

1002


What is difference between static and constant variable?

1036