示例#1
0
        private void New()
        {
            var customer = new Customer();
            var form     = new CadasterForm();

            form.Customer = customer;

            form.ShowDialog();
        }
示例#2
0
        private void ShowCustomer()
        {
            var selected = listView.SelectedItems.Cast <ListViewItem>().FirstOrDefault();

            if (selected == null)
            {
                return;
            }

            var form = new CadasterForm();

            form.Customer = (Customer)selected.Tag;

            form.ShowDialog();
        }