Fish in the river

思考 技术
记录 回忆
  1. Main page
  2. 软件开发
  3. C#
  4. Main content

wpf 使用CommunityToolKit.Mvvm实现绑定验证

2024年2月5日 86hotness 0likes 0comments

接上一个文章,我们在上一个文章中使用CommunityToolKit.Mvvm写了绑定。我们在这篇文章中,写一下绑定验证。

绑定验证在WPF系统中也是非常重要的一环。验证可以使得你的系统变得非常健壮。除非你的系统是游戏级别的自娱自乐级别。要么我都建议你加上验证。

还是那句老话,写程序一定要用成熟的技术。千万别用一些小众的框架。要不,到时有你受的。

同上篇文章,这篇文章的实现来自这位大神的文章。我只是将他原来使用mvvmLight的框架使用CommunityToolKit重新实现了一遍。

大神的文章如下。

https://www.cnblogs.com/wzh2010/p/6518834.html

重写的Demo源码如下。在Visual studio2022 + .net 6.0下编译实现。

立即下载
Tag: C#
Last updated:2024年2月5日

joey

This person is a lazy dog and has left nothing

Like
< Last article
Next article >

Comments

razz evil exclaim smile redface biggrin eek confused idea lol mad twisted rolleyes wink cool arrow neutral cry mrgreen drooling persevering
Cancel

归档

  • May 2025
  • April 2025
  • March 2025
  • February 2025
  • January 2025
  • December 2024
  • November 2024
  • October 2024
  • September 2024
  • August 2024
  • July 2024
  • June 2024
  • May 2024
  • April 2024
  • March 2024
  • February 2024

分类目录

  • C#
  • Dock
  • Excel
  • Kindle
  • Linux
  • Windows
  • 生活感悟
  • 群晖
  • 运维技术

COPYRIGHT © 2024 水中小鱼. ALL RIGHTS RESERVED.

Theme Kratos Made By Seaton Jiang