C# Interview Questions and Answers
<< Previous Question Next Question >>
 Question: 226 Page Views: 

How do you prevent property from being serialized?



Posted By: Avi Date: 13 October 2010 09:10:46 AM
 Answer:

by marking it with [NonSerialized()] attribute


Posted By: avibtech


Date: 13 October 2010 09:10:46 AM
Post a better Answer if you have
 
(Will show your Gravatar icon)  
  Country flag

Loading
Enter the text as shown in the image rNeuJW
Related Questions
C# : How do you subscribe to the event using Lambda expression:

How do you subscribe to the event using Lambda expression:

this.Click +=(s,e) => { /*code here*/; };
Category: C# Date: 10/13/2010 7:39:14 PM
C# : What does the as operator do?

What does the as operator do?

It perform conversion between compatible reference types
Category: C# Date: 10/13/2010 7:35:14 PM
C# : How do you define constraints on generic type parameters?

How do you define constraints on generic type parameters?

class Name<T> Where T: IConvertible {}
Category: C# Date: 10/13/2010 7:16:32 PM
C# : How do you write content of the list of string to the file in one line?

How do you write content of the list of string to the file in one line?

System.IO.File.WriteAllLines(path, list.ToArray());
Category: C# Date: 10/13/2010 7:11:31 PM
C# : How do you restrict access to the set accessor in property declaration?

How do you restrict access to the set accessor in property declaration?

public string Name { get { return name;} protected set { name = value;}}
Category: C# Date: 10/13/2010 7:06:46 PM