<?xml version="1.0" ?> <customStatesxmlns="http://schemas.microsoft.com/09/2005/communicator/customStates"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://schemas.microsoft.com/09/2005/communicator/customStateshttp://livecommteam/sites/main/ice/Wave%2012%20Docs/CustomActivities.xsd">
XmlTextWriter textWriter = new XmlTextWriter(xmlfile, null); XmlDocument doc = new XmlDocument();XmlNode docNode = doc.CreateXmlDeclaration("1.0", "", null);XmlNode customstate = doc.CreateElement("customStates");XmlAttribute customstateAttribute = doc.CreateAttribute("xmlns");customstateAttribute.Value = "http://schemas.microsoft.com/09/2005/communicator/customStates";customstate.Attributes.Append(customstateAttribute);customstateAttribute = doc.CreateAttribute("xmlns:xsi");customstateAttribute.Value = "http://www.w3.org/2001/XMLSchema-instance";customstate.Attributes.Append(customstateAttribute);customstateAttribute = doc.CreateAttribute("xsi:schemaLocation");customstateAttribute.Value ="http://schemas.microsoft.com/09/2005/communicator/customStateshttp://livecommteam/sites/main/ice/Wave%2012%20Docs/CustomActivities.xsd";customstate.Attributes.Append(customstateAttribute);doc.AppendChild(docNode);doc.AppendChild(customstate);doc.Save(textWriter);