public bool Load(string strFileName) { if (File.Exists(strFileName)) { try { ColumnStyleList columnStyleList = Webb.Utilities.Serializer.Deserialize(strFileName) as ColumnStyleList; this.Apply(columnStyleList); } catch (Exception ex) { System.Diagnostics.Debug.WriteLine(ex.Message); return(false); } return(true); } else { return(false); } }
public void Apply(ColumnStyleList columnStyleList) { this.FileName = columnStyleList.FileName; columnStyleList.ColumnStyles.CopyTo(this.ColumnStyles); }