|
 |
Implementing IClonable - Shallow copies
|
Total Hit (2698) |
An object that want to support cloning should implement the ICloneable interface. This interface exposes only one method, Clone, which returns a copy of the object. The ICloneable specifics don't specify whether the object that the Clone method returns is a shallow copy or a deep copy. The differenc
....Read More |
Rating
 |
|
 |
Implementing ICloneable - Deep copies
|
Total Hit (3531) |
The simplest way to create a generic deep copy routine, that is a procedure that can create a true, distinct copy of an object and all its dependent object, is to rely on the serialization features of the .NET framework.
«Code LangId=2»
Function CloneObject(ByVal obj As Object) As Object
'
....Read More |
Rating
 |
|
 |
Set up event handlers through reflection
|
Total Hit (2700) |
Reflection makes it easy to invoke a method (or assign a field or a property) by its name. For example, suppose you have the following classes:
«Code LangId=2»
Class Person
Event PropertyChanged(ByVal propertyName As String, ByVal newValue As Object)
Dim m_Name As String
Property
....Read More |
Rating
 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
 |
Object Oriented features in VB.net (Part-1)
|
Total Hit (6368) |
In this article we will discuss about Object Oriented Features available in VB.net
Let’s first understand the basic terminology used in Object Oriented Programming.
«big»Classes, Objects, Members and Abstraction«/big»
An object in programming is a construct that represents something from th
....Read More |
Rating
 |
|
 |
Object Oriented features in VB.net (Part-2)
|
Total Hit (11439) |
In the previous article we discussed the basic concepts of Object Oriented Programming. Now let's implement all this in our favorite language - VB.net.
«big»Creating Classes in VB.net«/big»
As we discussed earlier, objects are instances of a specific template – called a Class. A "Class" contai
....Read More |
Rating
 |
|
 |
Object Oriented features in VB.net (Part-3)
|
Total Hit (9139) |
«big»Inheritance«/big»
Now that VB.Net supports many object oriented features, lets discuss about Inheritance. Inheritance is the cornerstone of Object Oriented programming. VB.net supports inheritance and I am sure VB6 programmers will welcome this step. Inheritance gives us an ability to define
....Read More |
Rating
 |
|
 |
Working with DateTime and TimeSpan Object in VB.net
|
Total Hit (36237) |
In this article we will explore some key language features which are frequently used by VB programmers.
«big»DateTimes in VB.net«/big»
VB.net provides many new features for DateTime datatype. Unlike VB6 in VB.net you can initialize DateTime variable with verity of initial values. In VB.net you
....Read More |
Rating
 |
|