Example #1
0
        private void buttonRemoveSE_Click(object sender, EventArgs e)
        {
            var selRows = gridSocialExchanges.SelectedRows;

            if (selRows.Count == 0)
            {
                return;
            }
            foreach (var r in selRows.Cast <DataGridViewRow>())
            {
                var dto = ((ObjectView <SocialExchangeDTO>)r.DataBoundItem).Object;
                LoadedAsset.RemoveSocialExchange(dto.Id);
            }
            _socialExchangeList.DataSource = LoadedAsset.GetAllSocialExchanges().ToList();
            EditorTools.HighlightItemInGrid <SocialExchangeDTO>(gridSocialExchanges, Guid.Empty);
            SetModified();
        }