суббота, 12 марта 2011 г.
Check all checkboxes on the page wity JQuery
javascript:$("input[type=checkbox]").attr('checked', true);
среда, 9 февраля 2011 г.
C# Runtime objects comparison (find differences)
Put the following code to Immediate Window (Ctrl + Alt + I)
// Create StringWriter
System.IO.StringWriter stringWriter = new System.IO.StringWriter();
// Serialize object to the stringWriter.
new System.Xml.Serialization.XmlSerializer(obj.GetType()).Serialize(stringWriter, obj);
// Get serialized output.
stringWriter.ToString();
After you get xml strings for the serialized objs, that you wanted to compare you can easily compare this string in Araxis Merge or WinDiff tools.
// Create StringWriter
System.IO.StringWriter stringWriter = new System.IO.StringWriter();
// Serialize object to the stringWriter.
new System.Xml.Serialization.XmlSerializer(obj.GetType()).Serialize(stringWriter, obj);
// Get serialized output.
stringWriter.ToString();
After you get xml strings for the serialized objs, that you wanted to compare you can easily compare this string in Araxis Merge or WinDiff tools.
Подписаться на:
Сообщения (Atom)