/// <summary> /// Eventhandler for the PerformWork event on the _CustomerDS datasourcecontrol /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void _CustomerDS_PerformSelect(object sender, PerformSelectEventArgs2 e) { using (DataAccessAdapter adapter = new DataAccessAdapter()) { adapter.FetchEntityCollection(e.ContainedCollection, e.Filter, e.MaxNumberOfItemsToReturn, e.Sorter, e.PrefetchPath, e.PageNumber, e.PageSize); } }
/// <summary> /// Handles the PerformSelect Event of the LLBLGenProDataSource, which is raised when LivePersistence is set to false. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void EmployeeDetailsDS_PerformSelect(object sender, PerformSelectEventArgs2 e) { // use the DataAccessAdapter's FetchEntityCollection to fetch the contained collection // We don't need to pass anything to fetch method except the filter and the prefetchPath ( // to access the EmployeeSuperior related entity). DataAccessAdapter adapter = new DataAccessAdapter(); adapter.FetchEntityCollection(e.ContainedCollection, e.Filter, e.PrefetchPath); }