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...

Is string a value type or a reference type?

Answer Posted / sheetal shivdas

run this code : to see that string is reference type


SByte a = 0;
Byte be = 0;
Int16 c = 0;
Int32 d = 0;
Int64 ee = 0;
String s = "";
Exception ex = new Exception();

object[] Types = { a, be, c, d, ee, s,ex };

foreach (object obj in Types)
{
string type;
if (obj.GetType().IsValueType)
type = "Value Type";
else
type = "Reference Type";
Response.Write(type);
}

Is This Answer Correct ?    32 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain about solution explorer window?

1073


Can we have multiple master pages in asp net?

1031


What is application variable in asp.net?

976


Why we use asp.net for website development?

955


Why asp.net is used?

1049


What are the types of authentication in asp.net?

1069


In early binding will the method invoked on com component will verify it?s existance in the system or not ?

2690


How to use push notification?

1097


What is the adavantage of using ASP.NET routing?

1240


Is asp.net 64-bit enabled? How?

1109


What is round trip in asp.net?

983


What is the used of "ispostback" property?

1192


How to handle errors in Web API?

1249


What are the new data controls in asp.net 2.0?

1007


If you want to bind the columns manually within the asp:datagrid tags what kind of tags you have to add.

1092