Example on String Clone() Method.
The C# String Clone() method creates and returns a copy of string object. This methode returns a reference to this instance of string.
public class StringCloneExample
{
public static void Main()
{
string Str = "Clone Methode Testing";
string StrCloned = null;
StrCloned = (String)Str.Clone();
Console.WriteLine(StrCloned);
Console.ReadLine();
}
}
check here difference between clone and copy mthod
ReplyDeleteClone will copy the structure of a data where as Copy will copy the complete structure as well as data.
http://net-informations.com/faq/framework/clone-copy.htm
maaki