VB.NET INTERVIEW QUESTION & ANSWERS
61. |
What is the difference between boxing and unboxing? |
|
Boxing and unboxing act like bridges between value type and reference types. When we convert value type to a reference type it's termed as boxing. Unboxing is just like vice versa. |
62. |
What is reflection? |
|
- All .NET assemblies have metadata information stored about the types defined in modules. This metadata information can be accessed by mechanism called as Reflection.
- System. Reflection can be used to browse through the metadata information.
|
63. |
Is string a value type or a reference type? |
|
String is the reference type. |
64. |
Why is string called immutable data type? |
|
A string represents text and stores a sequential collection of characters in the memory.
A string object is said to be immutable (read-only), because a value once assigned to a string object
cannot be changed after the string object has been created. When the value in the string object is modified, a new string object is created with a new value assigned to the string object; therefore, keeping the old string in memory for garbage collector to be disposed. |
65. |
What is a session and application object? |
|
- Session object store information between HTTP requests for a particular user.
Session variables are used to store user specific information where as in application variables we can't store user specific information.
- while application object are global across users.
|