Win Surprise Gifts!!!
Top 5 Contributors of the Month
Post New Question
Subscribe to Interview Questions
How would one do a deep copy in .NET?
Posted By :
Syed Shakeer Hussain
Posted Date :
July 23, 2009
System.Array.CopyTo().it deep copies an array
You can also find related Interview Question to
How would one do a deep copy in .NET?
What is Deep copy and shallow copy?
Deep copy, copy the whole object and make a different object, it means it do not refer to the original object while in case of shallow copy the target object always refer to the original object and changes in target object also make changes in original object
What is object deep copy and shallow copy?
In deep copy the copy operations would respect the semantics of the object. For example, copying an object along with the objects to which it refers to.
A shallow copy copies an object without its contained objects.
what is a Deep Copy in .Net?
Deep copy is creating a new object and then copying the non static fields of the current object to the new object
What is Shadow Copy?
In order to replace a COM component on a live web server, it was necessary to stop the entire website, copy the new files and then restart the website. This is not feasible for the web servers that need to be always running. .NET components are different. They can be overwritten at any time using a mechanism called Shadow Copy. It prevents the Portable Executable (PE) files like DLLs and EXEs from being locked. Whenever new versions of the PEs are released, they are automatically detected by the CLR and the changed components will be automatically loaded. They will be used to process all new requests not currently executing, while the older version still runs the currently executing requests. By bleeding out the older version, the update is completed.
What should we do to copy the tables, schema and views from one SQL Server to another?
We have to write some DTS packages for it.
Whether BCP copy the table structure as it is?
No. It won't
Difference Between Dataset.Clone() and Dataset.Copy() ?
DataSet.Clone()--Reflects Only Schema to The Dataset
DataSet.Copy()--Retrives total Records to Dataset
What do you mean by Deep Zoom and Deep Zoom Composer?
Deep zoom helps to view high resolution images in silverlight application, using deep zoon one can zoom in and out with out affecting the performance of the application.
Deep zoom composer helps to create high resolution images for panning and smooth zooming.
How to disable Cut,Copy and Paste in a Text Box Control C# Windows Application ??
On the text box enter event, please have the below code
What is the main difference between DataSet.Clone() and DataSet.Copy() ?
DataSet.Clone() would copy only the schema of the DataSet object and it would return the DataSet object that has same struture that the previous dataset object which includes all the relations, constraints and schemas as well. This will not copy the data from the existing one to new one.
The existing Dataset ---
private DataSet CreateMyClone(DataSet myCloneDataSet)
exampleCloneDS = myCloneDataSet.Clone();
DataSet.Copy() will copy complete code as well as the structure of the existing DataSet object.
What is difference between Dataset.clone and Dataset.copy?
Dataset.Clone- It only copies structure, does not copy data.
Dataset.Copy - Copies both structure and data.
List How to copy tables,schema and views from one server to another?
-Detach database from one server and then attach database to another server
-Create Script of all objects and then run on another server
-User SSMS wizard
List commands to copy data from one table to another?
-Insert into select
are the two commands to copy data from one table to another.
Difference between DataSet Clone and DataSet Copy?
DataSet.Clone() - It only copies the structure but doesnot Copies the Data;
Dataset.Copy() - It copies both Structure and data..
Quick Links For Interview Questions Categories:
Find questions, FAQ's and their answers related to .NET, C#, Vb.Net, Sql Server and many more.
Now you can find lots of .NET, C#, Vb.Net, SQL Server,Windows, ASP.Net related Questions and their Answers here at www.dotnetspark.com. Our aim is to help you pass your certification Exams (MCP, MCSD, MCAD etc.,) with flying scores and get good name in your company.
So, Start looking our
section daily and improve your .NET Skills. You can also help others by posting Interview Questions and their Answers in this section.
Hall of Fame
Terms of Service
Tell A Friend