private DeleteProviderTypeRequest CreateRequest()
 {
     var request = new DeleteProviderTypeRequest
     {
         Id = _existingProviderTypeId
     };
     return request;
 }
        private void DeleteRecords()
        {
            try
            {
                foreach (var id in _viewModel.SelectedIds)
                {
                    var request = new DeleteProviderTypeRequest()
                    {
                        Id = int.Parse(id.ToString(), CultureInfo.InvariantCulture)
                    };

                    ProcessRequest<DeleteProviderTypeResponse>(request);
                }
                _viewModel.SelectedIds = new List<object>();
                _viewModel.SetSuccessMessage("Provider Types Successfully Deleted");
            }
            catch (Exception ex)
            {
                _viewModel.SetErrorMessage(ex.Message);
            }
        }