int IBaseBOL.GetCount(SearchFilterCollection sFilterCols) { int RecordCount = 1; string WhereCond = Tools.GetCondition(sFilterCols).Replace("''", "'"); var ResultQuery = new Khabardaan.Code.DAL.DBToolsDataContext().spGetCount(TableOrViewName, WhereCond); RecordCount = (int)ResultQuery.ReturnValue; return(RecordCount); }
public int GetCount(SearchFilterCollection sFilterCols) { string WhereCond; int RecordCount = 1; DBToolsDataContext dcTools = new DBToolsDataContext(); WhereCond = Tools.GetCondition(sFilterCols); if (WhereCond == "") { WhereCond = " NewsCode = " + MasterCode; } else { WhereCond = " NewsCode = " + MasterCode + " and " + WhereCond; } WhereCond = WhereCond.Replace("''", "'"); var ResultQuery = dcTools.spGetCount(TableOrViewName, WhereCond); RecordCount = (int)ResultQuery.ReturnValue; return(RecordCount); }