public bool verify()
{
if (!(File.Exists(xmlPath) && File.Exists(schemaPath)))
{
throw new customException("Schema or Config corrupted or doesn't exist");
}
//code to check if config matches schema
XmlSchemaSet xs = new XmlSchemaSet();
xs.Add("",schemaPath);
XmlReaderSettings setting = new XmlReaderSettings();
setting.ValidationType = ValidationType.Schema;
setting.Schemas = xs;
setting.ValidationEventHandler += new ValidationEventHandler(customEHandle);
XmlReader xr = XmlReader.Create(xmlPath, setting);
while (xr.Read()) ;
return isValid;
}