To delete a customer statistic, you have to perform the following:
NOTE: To delete multiple customer statistic instances, execute the code below for each one of them.
Here is a code example:
OrdersManager ordersManager = OrdersManager.GetManager();
CustomerStatistic customerStatistic = ordersManager.GetCustomerStatistic(customerStatisticId);
Customer customer = ordersManager.GetCustomers().SingleOrDefault(c => c.StatisticId == customerStatisticId);
//Customer statistic does not exist.
customer.StatisticId = Guid.Empty;
Back To Top