上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 13 下一页
摘要: 要求:年龄不满18 就边框飘红 后台代码: public class AgeInfoWithValidation : IDataErrorInfo { public int Age { get; set; } public string this[string columnName] { get { 阅读全文
posted @ 2021-02-08 13:48 蜜铀 阅读(114) 评论(0) 推荐(0) 编辑
摘要: 实现简单的年龄划分: 如果年龄小于18则显示:年龄:x,未成年人; 否则:年龄:x,成年人; 代码: [ValueConversion(typeof(int), typeof(String))] public class AgeConverter : IValueConverter { public 阅读全文
posted @ 2021-02-08 11:53 蜜铀 阅读(73) 评论(0) 推荐(0) 编辑
摘要: 验证用户是否年满18+ public class AgeRule : ValidationRule { private Double limitAge = 18; public Double LimitAge { get { return limitAge; } set { limitAge = v 阅读全文
posted @ 2021-02-08 11:35 蜜铀 阅读(196) 评论(0) 推荐(0) 编辑
摘要: 代码如下: DataTemplate :使用黄色着色 ControlTemplate : 使用蓝色着色 <Button Content="Button"> <Button.ContentTemplate > <DataTemplate> <Label Background="Yellow" Cont 阅读全文
posted @ 2021-02-07 16:47 蜜铀 阅读(46) 评论(0) 推荐(0) 编辑
摘要: 有些文件夹还不能删除,这就需要强力删除的方法: 1、左下角选择Windows Logo,输入cmd 2、管理员身份运行cmd 3、录入: RD /S 文件夹路径 弹窗选择‘是’ 阅读全文
posted @ 2020-12-01 16:04 蜜铀 阅读(848) 评论(0) 推荐(0) 编辑
摘要: 这两天同事在使用Java 的ping方法的时候,发现在Windows环境下可以正常ping通的,而在centOS(Linux)里面无法ping通。 代码如下: boolean status = InetAddress.getByName(ipAddress).isReachable(timeOut) 阅读全文
posted @ 2020-11-20 16:52 蜜铀 阅读(2725) 评论(0) 推荐(0) 编辑
摘要: 很多时候,由于后台线程需要直接控制相关主线程的工作。 如果直接使用则会出现如下类似的异常: System.NotSupportedException:“该类型的 CollectionView 不支持从调度程序线程以外的线程对其 SourceCollection 进行的更改。” 方法一 在窗体初始化的 阅读全文
posted @ 2020-11-16 14:17 蜜铀 阅读(991) 评论(0) 推荐(0) 编辑
摘要: 该方法可适用于所欲容器类型,相关属性:ClipToBounds 举例: 代码: <Canvas ClipToBounds="False" Height="100" Width="100" Background="Yellow"> <Ellipse Fill="Green" Height="100" 阅读全文
posted @ 2020-11-15 22:50 蜜铀 阅读(367) 评论(0) 推荐(0) 编辑
摘要: 如果后台没有运行ros,则: 开启ros roscore 获取 rosparam get /rosdistro 阅读全文
posted @ 2020-10-21 10:39 蜜铀 阅读(2007) 评论(0) 推荐(0) 编辑
摘要: 为了只上传有意义的代码,我安装了一个ignore插件 第一步,安装插件 第二步,使用ignore插件快速插入要git忽略的内容 重启后 打开 .gitignore, 并在文本上用快捷键 alt + Insert, 选择.ignore file >> .gitignore file(git) 接着筛选 阅读全文
posted @ 2020-10-07 16:11 蜜铀 阅读(1165) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 13 下一页