首先说明

在SelectTemplate中并Item参数并不是真的一直为Null。而是先执行空参数,之后再会执行有参数的。

至于原因 我也不知道...

 

具体验证过程是

 WPF DataGrid 使用CellTemplateSelector 时SelectTemplate方法Item参数为NULL

也就说 做好非空检测即可

相关文章:

  • 2021-07-19
  • 2022-12-23
  • 2021-11-13
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-11-18
  • 2022-02-28
  • 2022-12-23
  • 2022-12-23
  • 2021-08-26
相关资源
相似解决方案