public GridViewSummary RegisterSummary(string column, string formatString, SummaryOperation operation, string groupName) { if (operation == SummaryOperation.Custom) { throw new Exception(USE_ADEQUATE_METHOD_TO_REGISTER_THE_SUMMARY); } GridViewGroup group = mGroups[groupName]; if (group == null) { throw new Exception(String.Format(GROUP_NOT_FOUND, groupName)); } // TO DO: Perform column validation... GridViewSummary s = new GridViewSummary(column, formatString, operation, group); group.AddSummary(s); return(s); }
public GridViewSummary RegisterSummary(GridViewSummary s) { if (!s.Validate()) { throw new Exception(INVALID_SUMMARY); } if (s.Group == null) { // if general summaries are displayed in the footer, it must be set to visible if (useFooter) { mGrid.ShowFooter = true; } mGeneralSummaries.Add(s); } else if (!s.Group.ContainsSummary(s)) { s.Group.AddSummary(s); } return(s); }
public bool ContainsSummary(GridViewSummary s) { return(mSummaries.Contains(s)); }
public void AddSummary( GridViewSummary s) { if (this.ContainsSummary(s)) { throw new Exception("Summary already exists in this group."); } if (!s.Validate()) { throw new Exception("Invalid summary."); } ///s._group = this; s.SetGroup(this); this.mSummaries.Add(s); }
public bool ContainsSummary(GridViewSummary s) { return mSummaries.Contains(s); }
public GridViewSummary RegisterSummary(GridViewSummary s) { if (!s.Validate()) { throw new Exception(INVALID_SUMMARY); } if (s.Group == null) { // if general summaries are displayed in the footer, it must be set to visible if (useFooter) mGrid.ShowFooter = true; mGeneralSummaries.Add(s); } else if (! s.Group.ContainsSummary(s)) { s.Group.AddSummary(s); } return s; }
public GridViewSummary RegisterSummary(string column, string formatString, CustomSummaryOperation operation, SummaryResultMethod getResult, string groupName) { GridViewGroup group = mGroups[groupName]; if (group == null) { throw new Exception(String.Format(GROUP_NOT_FOUND, groupName)); } // TO DO: Perform column validation... GridViewSummary s = new GridViewSummary(column, formatString, operation, getResult, group); group.AddSummary(s); return s; }
public GridViewSummary RegisterSummary(string column, string formatString, CustomSummaryOperation operation, SummaryResultMethod getResult) { // TO DO: Perform column validation... GridViewSummary s = new GridViewSummary(column, formatString, operation, getResult, null); mGeneralSummaries.Add(s); // if general summaries are displayed in the footer, it must be set to visible if (useFooter) mGrid.ShowFooter = true; return s; }
public GridViewSummary RegisterSummary(string column, string formatString, SummaryOperation operation, string groupName) { if (operation == SummaryOperation.Custom) { throw new Exception(USE_ADEQUATE_METHOD_TO_REGISTER_THE_SUMMARY); } GridViewGroup group = mGroups[groupName]; if (group == null) { throw new Exception(String.Format(GROUP_NOT_FOUND, groupName)); } // TO DO: Perform column validation... GridViewSummary s = new GridViewSummary(column, formatString, operation, group); group.AddSummary(s); return s; }
public GridViewSummary RegisterSummary(string column, string formatString, SummaryOperation operation) { if (operation == SummaryOperation.Custom) { throw new Exception(USE_ADEQUATE_METHOD_TO_REGISTER_THE_SUMMARY); } // TO DO: Perform column validation... GridViewSummary s = new GridViewSummary(column, formatString, operation, null); mGeneralSummaries.Add(s); // if general summaries are displayed in the footer, it must be set to visible if (useFooter) mGrid.ShowFooter = true; return s; }