一个简单的c# 弹幕游戏,游戏开始后,按上下左右来控制箭头的移动,来生存。
2021-07-20 14:59:27 268KB 游戏 c# Winform
1
非常详细的水晶报表使用教程(作者亲测),包涵数据库
2021-07-20 14:13:15 322KB 水晶报表
1
C# WinForm开发初级入门,从简单的窗体开发到完整窗体应用程序开发,并有相关的VS教程,PPT文件,新手必备
2021-07-20 13:02:08 16.01MB C#
1
C# Winform 美化了 TabControl
2021-07-20 11:34:54 185KB tabControl 标签页 美化
1
此程序可以用来读取赛多利斯电子天平的称重读数,但程序中读数部分代码需要自行提取,属于电子天平读数的代码可参考https://mp.csdn.net/postedit/80812561
2021-07-20 10:25:44 10KB winform 串口通信 电子天平读数
1
c#winform插入各种ECharts统计图
2021-07-19 20:09:12 836KB c# 统计图 echart
1
C# WinForm跨窗体委托实现在窗体2中输入数据显示在窗体1中的dataGridView
1
c# winform 在线答题项目,windows应用程序,有数据库和完整代码,望c#学者喜欢。
2021-07-17 10:47:02 1.99MB 在线答题项目
1
winform实现PPT展示特效:从网上找的,整理的,这是其中一个特效的代码 #region 压缩反转(改进版) // 原理:计算图像位置和高度,以高度的一半为轴进行对换上下半边的图像 private void Animator01() { const float blockSize = 8; // 每次显示的高度增量,应能被高度整除 try { OnDrawStarted(this, EventArgs.Empty); // 触发开始绘制事件 //ClearBackground(); Color bgColor = Color.FromKnownColor(KnownColor.ButtonFace); RectangleF srcRect = new RectangleF(0, 0, bmp.Width, bmp.Height); for (float i = (float)Math.Floor(-bmp.Height / blockSize); i <= Math.Ceiling(bmp.Height / blockSize); i++) { dc.Clear(bgColor); // 清空DC float j = i * blockSize / 2; float destTop = bmp.Height / 2 - j; // 目标矩形的顶位置 // 目标矩形区域在循环的前半段为垂直反向 RectangleF destRect = new RectangleF(0, destTop, bmp.Width, 2 * j); // 在指定区域绘制图像,该图像被拉伸 dc.DrawImage(bmp, destRect, srcRect, GraphicsUnit.Pixel); ShowBmp(); Thread.Sleep(10 * delay); // 休眠 } } catch (Exception ex) { ShowError(ex.Message); } finally { OnDrawCompleted(this, EventArgs.Empty); // 触发完成绘制事件 } } #endregion
2021-07-16 19:02:30 3.39MB winform C# C#winform winform特效
1
前面的一篇文章C# WinForm控件美化扩展系列之ListView(2)中,存在列表项文本错乱的问题,这是因为绘制文本的时候不小心选错了一个属性,把SubItem选成了Item,所以总会得到了第一项的文本。除了修正这个错误外,对列表项选中后的背景画法进行了改变,使得选中的列表项不在是每个子项都有一个矩形边框,而是全部只有一个矩形边框。另外,实现了对ListView的边框的重绘,可以轻易的更换边框颜色。 如下: private void WmNcPaint(ref Message m) { base.WndProc(ref m); if (base.BorderStyle == BorderStyle.None) { return; } IntPtr hDC = NativeMethods.GetWindowDC(m.HWnd); if (hDC == IntPtr.Zero) { throw new Win32Exception(); } try { Color backColor = BackColor; Color borderColor = _borderColor; Rectangle bounds = new Rectangle(0, 0, Width, Height); using (Graphics g = Graphics.FromHdc(hDC)) { using (Region region = new Region(bounds)) { region.Exclude(AbsoluteClientRectangle); using (Brush brush = new SolidBrush(backColor)) { g.FillRegion(brush, region); } } ControlPaint.DrawBorder( g, bounds, borderColor, ButtonBorderStyle.Solid); } } finally { NativeMethods.ReleaseDC(m.HWnd, hDC); } m.Result = IntPtr.Zero; }
2021-07-16 12:00:10 161KB c#
1