摘要:
自定义TreeDataView 控件,百万级别数据秒绘。 最近需要使用到数据展现,需要对数据折叠展现。网上找了许多控件,如:TreeListView,TreevDataGirdView等,但是都无法到达效果,而且加载百万条数据时,绘制灰常的卡顿。 话不多说。先上效果图 1 准备工作,创建两个类,用户
阅读全文
posted @ 2020-12-02 15:34
永恒921
阅读(322)
推荐(1)
摘要:
效果实现如下: 金属仪表盘下载地址 https://pan.baidu.com/s/1xANmSkQYnLGzUJ_X8Dbg0w 提取码:fi96
阅读全文
posted @ 2018-11-13 10:34
永恒921
阅读(8778)
推荐(0)
摘要:
WPF 程序使用 MediatR 1 修改App.xam 让WPF应用启动时不要直接实例化主窗口,而是通过DI获取 删除掉 StartupUri="Views\MainWindow.xaml" <Application x:Class="YourNamespace.App" xmlns="http:
阅读全文
posted @ 2024-06-29 15:50
永恒921
阅读(107)
推荐(1)
摘要:
1 添加服务类 WebServiceHost using System.ServiceModel; using System.ServiceModel.Web; using System.Web.Services.Protocols; [ServiceContract(Namespace = "ht
阅读全文
posted @ 2024-03-07 18:14
永恒921
阅读(33)
推荐(0)
摘要:
1 从NUGET添加组件“Swashbuckle.AspNetCore” 相关使用代码 var builder = WebApplication.CreateBuilder(); builder.Services.AddControllers(); var app = builder.Build()
阅读全文
posted @ 2024-03-07 17:37
永恒921
阅读(591)
推荐(0)
摘要:
多线程等待 温故而知新,好久没有用到,突然忘记 方法一 CountDownEvent 类 using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Thread
阅读全文
posted @ 2022-11-15 09:09
永恒921
阅读(27)
推荐(0)
摘要:
好久没用都要忘记了,记录下,温故而知新。 1. 播放系统事件声音 System.Media.SystemSounds.Asterisk.Play(); System.Media.SystemSounds.Beep.Play(); System.Media.SystemSounds.Exclamati
阅读全文
posted @ 2021-11-29 14:32
永恒921
阅读(3015)
推荐(0)
摘要:
winform datagridview 刷新数据不需要重新绑定以及添加COMBOX方法 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using Sys
阅读全文
posted @ 2021-09-14 19:56
永恒921
阅读(4522)
推荐(0)
摘要:
一个非常好用的windform界面布局设计控件“WeifenLuo.WinFormsUI.Docking” github上的开源代码地址:https://github.com/dengwei1008/WinForms GitHub地址Demo:https://github.com/gdoujkzz/
阅读全文
posted @ 2021-08-26 09:22
永恒921
阅读(416)
推荐(0)
摘要:
【转】Castle Windsor之组件注册 注册方式较多,大体有这么几种,学习得比较粗浅,先记录: 1、逐个注册组件即对每个接口通过代码指定其实现类,代码: container.Register( Component.For<IMyService>() //接口 .ImplementedBy<My
阅读全文
posted @ 2021-06-16 15:06
永恒921
阅读(120)
推荐(0)
摘要:
XAML <UserControl x:Class="RpowerMonitor_MCS.UserControls.ProgressBarControl" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:
阅读全文
posted @ 2021-05-26 14:12
永恒921
阅读(303)
推荐(0)
摘要:
通常我们在程序中需要调用WebService时,都是通过“添加Web引用”,让VS.NET环境来为我们生成服务代理,然后调用对应的Web服务。这样是使工作简单了,但是却和提供Web服务的URL、方法名、参数绑定在一起了,这是VS.NET自动为我们生成Web服务代理的限制。如果哪一天发布Web服务的U
阅读全文
posted @ 2021-05-24 15:16
永恒921
阅读(885)
推荐(2)
摘要:
using System; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Text; using System.Threading.Tasks; using
阅读全文
posted @ 2020-09-25 11:55
永恒921
阅读(279)
推荐(0)
摘要:
/// <summary> /// 禁用窗体最大最小按键 /// </summary> internal static class WindowExtensions { [DllImport("user32.dll")] internal extern static int SetWindowLon
阅读全文
posted @ 2020-09-22 15:10
永恒921
阅读(431)
推荐(0)
摘要:
public class testDescrible { int _tt; [Description("123")] public int ttt { get { return _tt; } set { _tt = value; } } [Description("测试1")] public voi
阅读全文
posted @ 2020-09-22 14:37
永恒921
阅读(2340)
推荐(0)
摘要:
WPF 接收初始化 /// <summary> /// 初始化窗体句柄消息接收函数 /// </summary> private void InitailWinHand() { HwndSource hWndSource; WindowInteropHelper wih = new WindowIn
阅读全文
posted @ 2020-09-22 12:29
永恒921
阅读(957)
推荐(0)
摘要:
public static object GetElementFromPoint(System.Windows.Controls.ItemsControl itemsControl, Point point) { UIElement element = itemsControl.InputHitTe
阅读全文
posted @ 2020-09-22 11:44
永恒921
阅读(657)
推荐(0)
摘要:
/// <summary> /// 检测IP地址是否合法 /// </summary> /// <param name="strJudgeString"></param> /// <returns></returns> public static bool JudgeIPFormat(string
阅读全文
posted @ 2020-09-22 11:41
永恒921
阅读(684)
推荐(0)
摘要:
/// <summary> /// 带小数点数字匹配 /// </summary> /// <param name="input"></param> /// <returns></returns> public static bool IsNumber(string input) { string
阅读全文
posted @ 2020-09-22 11:33
永恒921
阅读(6295)
推荐(0)
摘要:
C#中实现文件拖放打开的方法 设置Form属性 AllowDrop = True; 在Form事件中 private void Form1_DragDrop(object sender, DragEventArgs e) { string localFilePath = ((System.Array
阅读全文
posted @ 2020-02-28 15:10
永恒921
阅读(1160)
推荐(0)
摘要:
修改注册表,双击文件直接打开 string strProject = "Exec"; string p_FileTypeName =".cdb";//文件后缀 string fileName = System.Windows.Forms.Application.ExecutablePath;// 获
阅读全文
posted @ 2020-02-28 15:04
永恒921
阅读(1211)
推荐(0)