Serializing DataTable and About our session "Insights on Enterprise Services"

every time I meet roy and I want to blog about what happened I w8 a bit for Roy to blog about it.

I enjoy reading his reviews and comments , so instead of telling you how it was you can read all about it here

you can get the Presentation and code HERE

It was the first time Lior had presented a topic and the first time for both of us to speak ion the same session, It was by far the best session I've attended as a speaker. we had lot's of laugh's and many technical problems, for some reason the video out of our xbox (2 consoles) was off, MS invited a person to fix it who made a lot of noise. but still it was great.

at the end we plugged in the xbox and played halo.

at the session itself we said that DataTable doesn't support Serialization, someone approached me at the break and told me that it does support, I said let's take a look at the msdn:

 [C#]
[Serializable]
public class DataTable : MarshalByValueComponent, IListSource, 
   ISupportInitialize, ISerializable
 so I opened Reflector and there it was:
 private void System.Runtime.Serialization.ISerializable.GetObjectData(SerializationInfo info, StreamingContext context){ 

bool flag1;DataSet set1;flag1 = false;if (this.dataSet == null){

set1 = new DataSet("tmpDataSet");set1.Tables.Add(this);flag1 = true;

}info.AddValue("XmlSchema", this.dataSet.GetXmlSchemaForRemoting(this));info.AddValue("XmlDiffGram", this.dataSet.GetRemotingDiffGram(this));if (flag1){

this.dataSet.Tables.Remove(this);

}

}

 

what it's doing is creating a dataset and serializing it. so It was cool showing it to people.