AjaxControlToolkit.Reference.Core.Documentation.LoadXml C# (CSharp) Метод

LoadXml() статический приватный Метод

static private LoadXml ( string fileName ) : System.Xml.Linq.XDocument
fileName string
Результат System.Xml.Linq.XDocument
        static XDocument LoadXml(string fileName)
        {
            XDocument xml;
            if(!File.Exists(fileName))
                throw new ArgumentException(String.Format("File '{0}' not found", fileName), "fileName");

            xml = XDocument.Load(fileName);
            if(xml == null)
                throw new ArgumentException(String.Format("Unable to load XML from '{0}'", fileName), "fileName");

            return xml;
        }