2022年4月6日

ViewModel模板

摘要: #region 属性 #endregion #region 命令 #endregion #region 公共方法 #endregion #region 私有方法 #endregion 阅读全文

posted @ 2022-04-06 10:23 lopengye 阅读(18) 评论(0) 推荐(0)

自动编译命令行

摘要: 自动编译命令行@echo off title Build Projectecho 1. Rebuild Release Project, Please Wait...rem 2.rebuild Releaserem 务必根据本地电脑上的 vs 选择对应的 devenv.exestart /high 阅读全文

posted @ 2022-04-06 10:22 lopengye 阅读(50) 评论(0) 推荐(0)

2022年3月8日

WPF ListBox ListView ScrollViewer ScrollBar 样式例子

摘要: <Color x:Key="DisabledForegroundColor">#FF888888</Color> <Color x:Key="ControlPressedColor">#FF211AA9</Color> <Style x:Key="ScrollBarLineButton" Targe 阅读全文

posted @ 2022-03-08 17:53 lopengye 阅读(382) 评论(0) 推荐(0)

WPF 向四周扩散的阴影

摘要: <DropShadowEffect Color="#FFDCDFE8" BlurRadius="20" Direction="0" ShadowDepth="0" Opacity="0.5" /> 阅读全文

posted @ 2022-03-08 14:27 lopengye 阅读(148) 评论(0) 推荐(0)

2022年2月28日

C# 更新配置文件的值AppSetting

摘要: private void AddUpdateAppSettings(string key, string value) { try { var configFile = ConfigurationManager.OpenExeConfiguration(ConfigurationUserLevel. 阅读全文

posted @ 2022-02-28 11:31 lopengye 阅读(598) 评论(0) 推荐(0)

2022年1月21日

Beyond Compare 4 延长试用时间方法

摘要: 计算机\HKEY_CURRENT_USER\SOFTWARE\Scooter Software\Beyond Compare 4\CacheID 这一项删除,恢复30天试用 阅读全文

posted @ 2022-01-21 10:32 lopengye 阅读(94) 评论(0) 推荐(0)

2022年1月20日

十六进制字符串转数字Int32

摘要: int area2 = Convert.ToInt32($"0x0401", 16); 阅读全文

posted @ 2022-01-20 10:56 lopengye 阅读(427) 评论(0) 推荐(0)

2022年1月14日

WPF C# 以非独占式读取本地图片

摘要: 思路是先把图片读取到内存中,再转换成BitmapImage 代码: string imgPath = "X:\\xxxxx.jpg"; var bytes = File.ReadAllBytes(imgPath); MemoryStream ms = new MemoryStream(bytes); 阅读全文

posted @ 2022-01-14 09:43 lopengye 阅读(444) 评论(0) 推荐(1)

2021年12月2日

WPF自定义控件踩坑记录,用户自定义控件 绑定后台定义的 命令 依赖项属性 注意事项 静态

摘要: 项目中做了一个拼音键盘的自定义控件,主要作用是在该控件上打字并输出到引用的页面上。 由于代码中有很多按钮,这些按钮的Command都被绑定到自定义控件的后台代码的一个静态命令上了。。。。。。。 private static readonly RoutedCommand _clickCmd = new 阅读全文

posted @ 2021-12-02 14:31 lopengye 阅读(611) 评论(0) 推荐(0)

2021年11月5日

Bitmap.Save出现GDI+中发生一般性错误

摘要: 检查一下,你要保存的路径文件夹是否存在,文件夹不存在要先新建文件夹!!! 阅读全文

posted @ 2021-11-05 13:35 lopengye 阅读(312) 评论(1) 推荐(0)

导航