回复 10楼cn2008liulin的帖子
在这个例子里,Details列是和绑定Product的Name列,所以只需更改product.Name,绑定的C1FlexGrid列就会做改变。
修改的代码参考:
- private void ShowDetail_Click(object sender, RoutedEventArgs e)
- {
- //int m_row=2, m_col=6;
- var product = GetProduct(sender);
- if (product != null)
- {
- //var detail = string.Format("Product {0}, Color {1}, Rating {2}",
- // product.Name, product.Color, product.Rating);
- //MessageBox.Show(detail, "Detail", MessageBoxButton.OK);
- Window1 w = new Window1();
- if (w.ShowDialog().HasValue)
- {
- product.Name = (w.retuen_v!=string.Empty) ? w.retuen_v : product.Name;
- }
- //_flex[m_row, m_col] = w.retuen_v;
- }
- }
复制代码 |