What is Boxing and Unboxing?
Answer Posted / eduardo belmonte
Boxing is the process of converting value type to reference
type.
Unboxing is the process of converting from a reference type
to a value type.
Both are slow and should be avoided when possible or
unneeded.
Dim st AS String
Dim obj As Object
Dim n As Integer = 5
st = n ' Boxing happens
obj = n ' Boxing happens
n = st ' Unboxing happens
n = obj ' Unboxing happens
| Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
What are the advantages of the code-behind feature?
How do session tokens work?
What are the differences between clr & cts?
Where is asp.net session stored?
Difference between response.redirect and server.transfer?
Which adapter should you use, if you want to get the data from an access database?
What are server activated objects?
What is difference between asp state management and asp.net state management? How can we pass info between 2 asp.net pages?
can we remote debug applications with the remote debugger installed with vs.net 2002, with vs.net 2003?
When was asp.net released?
What is the maximum timeout we can set for Cookies?
what is silver light when will we use silver light,
Should I delete cookies?
What is difference between ispostback and autopostback in asp net?
Is sql backend or frontend?