How do I automatically resize the Form when the screen resolution changes between design-time and runtime?

The framework automatically resizes the form if the current Font size during runtime is different from the font size in design-time. It however doesn’t auto size when the resolution changes. But it should be easy for you to accomplish. You could derive a custom Form, provide a ‘ScreenResolutionBase’ property that could return the current screen resolution (Screen.PrimarScreen.Bounds will give you this). This value will get serialized in code during design time. Then during runtime in the Form’s OnLoad you could check for the current screen resolution and resize the Form appropriately.

How do I add an XmlNode from one XmlDocument to an XmlNode in another XmlDocument?

The XmlNode.AppendChild restricts you to add XmlNodes originated in the same XmlDocument. So, to do the above, here is a sample workaround: [C#] // destParent and sourceParent are from different XmlDocuments. // This method will append the children of sourceParent to the destParent’s children. public static void TransferChildren(XmlDocument destDoc, XmlNode destParent, XmlNode sourceParent) { // Create a temporary element into which we will add the children. XmlElement tempElem = destDoc.CreateElement(‘Temp’); tempElem.InnerXml = sourceParent.InnerXml; foreach(XmlNode node in tempElem.ChildNodes) destParent.AppendChild(node); } [VB.Net] ’ destParent and sourceParent are from different XmlDocuments. ’ This method will append the children of sourceParent to the destParent’s children. Public Static Sub TransferChildren(ByVal destDoc As XmlDocument, ByVal destParent As XmlNode, ByVal sourceParent As XmlNode) ’ Create a temporary element into which we will add the children. Dim tempElem As XmlElement = destDoc.CreateElement(‘Temp’) tempElem.InnerXml = sourceParent.InnerXml Dim node As XmlNode For Each node In tempElem.ChildNodes destParent.AppendChild(node) Next End Sub