在WPF数据网格中获取单元格值 [英] Get cell value in WPF datagrid

查看:85
本文介绍了在WPF数据网格中获取单元格值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嘿所有,



在我的WPF应用程序中,我有一个数据网格,现在我想得到一个单元格的值。

我已经尝试了几十种可能的解决方案但是没有一种能够正常工作。



你能帮助我吗?



Greetz,A

解决方案

此讨论 [ ^ ]可以帮助你。


哇,根据http://social.msdn.microsoft.com/Forums/en/wpf/thread/74332b78-6bfd-4ac9 -af85-dfd9bec87a29 [ ^ ],这不是应该的那么简单。


Colin Eberhardt在WPF数据网格上写了一篇很好的文章WPF DataGrid实际示例 [ ^ ] - 我会在直接使用单元格之前查看数据绑定。



最好的问候

Espen Harlinn

Hey all,

In my WPF application I have a datagrid and now I want to get the value of a cell.
I have tried dozens of possible solutions but none of them are working.

Can you guys help me out?

Greetz, A

解决方案

This discussion[^] could help you out.


Wow, according to http://social.msdn.microsoft.com/Forums/en/wpf/thread/74332b78-6bfd-4ac9-af85-dfd9bec87a29[^], that's not as trivial as it should be.


Colin Eberhardt did a nice article on the WPF datagrid WPF DataGrid Practical Examples[^] - I would certainly look at databinding before working directly with the cells.

Best regards
Espen Harlinn


这篇关于在WPF数据网格中获取单元格值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆