<PackageReference Include="System.Configuration.ConfigurationManager" Version="7.0.0-preview.7.22375.6" />

ConfigurationException

A config exception can contain a filename (of a config file) and a line number (of the location in the file in which a problem was encountered). Section handlers should throw this exception (or subclasses) together with filename and line number information where possible.
public virtual string BareMessage { get; }

public virtual string Filename { get; }

public virtual int Line { get; }

public ConfigurationException(string message)

public ConfigurationException(string message, Exception inner)

public ConfigurationException(string message, XmlNode node)

public ConfigurationException(string message, Exception inner, XmlNode node)

public ConfigurationException(string message, string filename, int line)

public ConfigurationException(string message, Exception inner, string filename, int line)

public static string GetXmlNodeFilename(XmlNode node)

public static int GetXmlNodeLineNumber(XmlNode node)