private void Load(LoadAux function) { if (string.IsNullOrEmpty(config)) { Log.Error("Configuration filename is null or empty in Project::LoadConfig "); return; } XmlDocument doc = new XmlDocument(); try { doc.Load(config); function(doc); } catch (Exception e) { Log.Error("Error loading configuration file!"); Log.Error(e.ToString()); } }
private void Load( LoadAux function ) { if( string.IsNullOrEmpty( config ) ) { Log.Error( "Configuration filename is null or empty in Project::LoadConfig " ); return; } XmlDocument doc = new XmlDocument(); try { doc.Load( config ); function( doc ); } catch( Exception e ) { Log.Error( "Error loading configuration file!" ); Log.Error( e.ToString() ); } }