-
程序守护(进程守护)-源代码C#
程序守护(进程守护)-源代码C#
/*
* 由SharpDevelop创建。
* 用户: zhang
* 日期: 2017/3/18
* 时间: 21:50
* 要改变这种模板请点击 工具|选项|代码编写|编辑标准头文件
*/
using System;
using System.Diagnostics;
using System.Drawing;
using System.Threading;
using System.Windows.Forms;
namespace CPinfoSafe
{
public sealed class NotificationIcon
{
private NotifyIcon notifyIcon;
private ContextMenu notificationMenu;
DialogResult dr;
#region Initialize icon and menu
public NotificationIcon()
{
notifyIcon = new NotifyIcon();
notificationMenu = new ContextMenu(InitializeMenu());
notifyIcon.DoubleClick += IconDoubleClick;
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(NotificationIcon));
notifyIcon.Icon = (Icon)resources.Get
- 2022-11-01 19:35:03下载
- 积分:1
-
C# 立方体三维旋转动画实例代码
C# 玩转三维空间,编写实现一个立方体的三维旋转动画特效,运行本程序,会看到窗口中有一个3D立方体,不停旋转,视角改变平滑,看似简单的动画,实际上编写起来挺麻烦,代码文件比较多,而且是一个来自国外的C# 源代码,注释也是英文的,这个实例用到了C#的float、ThreeDMatrix()、ThreeDObject()、ThreeDPolygon(points)、ThreeDPoint、ArrayList()等众多方法,对学习C#的图像渲染有一定参考价值。
- 2023-01-09 01:55:03下载
- 积分:1
-
C# WPF演示窗体模式的切换
C# WPF演示窗体模式的切换,可以切换到拖放模式,切换到编辑模式。编辑模式切换的例子。
- 2022-05-14 05:31:05下载
- 积分:1
-
C# 写入并读取内存流
C# 写入并读取内存流,演示一些基本的内存流操作方法,编写以下代码可实现这些功能:
byte[] BContent = Encoding.Default.GetBytes(textBox1.Text);
MemoryStream MStream = new MemoryStream(100);
MStream.Write(BContent, 0, BContent.Length);
richTextBox1.Text = "分配给该流的字节数:" + MStream.Capacity.ToString() + "
流长度:"
+ MStream.Length.ToString() + "
流的当前位置:" + MStream.Position.ToString();
MStream.Seek(0, SeekOrigin.Begin);
byte[] byteArray = new byte[MStream.Length];
int count = MStream.Read(byteArray,0,(int)MStream.Length-1);
while (count < MStream.Length)
{
byteArray[count++] = Convert.ToByte(MStream.ReadByte());
}
char[] charArray = new char[Encoding.Default.GetCharCount(byteArray, 0, count)];
Encoding.Default.GetChars(byteArray, 0, count, charArray, 0);
for (int i = 0; i < charArray.Length; i++)
{
richTextBox2.Text += charArray[i].ToString();
}
- 2022-03-11 09:55:00下载
- 积分:1
-
C# 源码实现微信打印机
C# 源码实现微信打印机,这个没搞懂是一个什么程序,用C#写的微信相关程序,有兴趣的可以参考一下,项目源码结构图如图所示。
- 2022-03-17 18:21:17下载
- 积分:1
-
C# 通用权限管理框架源码 ERP OA 快速开发框架
1、菜单导航管理2、操作按钮3、角色管理4、部门管理5、用户管理(用户权限)6、用户组管理(设置成员,用户组权限)7、系统配置(动态配置系统参数)8、附加属性(自定义属性)9、系统日志(异常记录)10、数据库备份/还原11、资源管理,(动态数据库)12、个人信息(基本信息,附加信息,用户角色,拥有权限)13、首页快捷14、数据回收站(业务功能删除过数据,全部保留在回收站)15、系统个性化设置(切换菜单导航)
- 2022-03-11 07:50:58下载
- 积分:1
-
C# 启动和关闭无窗体定时器
C# 启动和关闭无窗体定时器,单击窗体上对应的按钮,即可完成无窗体定时器的启动和关闭功能,核心代码为:
private void button1_Click(object sender, EventArgs e)
{//启动无窗体定时器
var MyClass = new MyThreadClass();
MyTimer = new System.Threading.Timer(MyClass.MyCallBackMethod, MyClass, 5000, 2000);
}
private void button2_Click(object sender, EventArgs e)
{//关闭无窗体定时器
MyTimer.Dispose();
}
- 2022-04-09 03:53:39下载
- 积分:1
-
lua
lua源码 可编译 安装 使用库 内有说明文档readme.html lua是广泛使用的脚本语言,用途广泛
- 2023-03-10 12:30:04下载
- 积分:1
-
C# 设置应用程序背景颜色
C# 设置应用程序背景颜色,通过调用Windows调色板,来选取颜色,然后程序将颜色值赋值给窗口,此盒子可设置斜体的颜色值,运行效果如参考截图所示,核心代码请看以下代码片段:
private void Form1_Load(object sender, EventArgs e)
{//显示应用程序背景颜色
//先打开“Properties”,添加一个System.Drawing.Color类型的变量MyBackColor
this.BackColor = Properties.Settings.Default.MyBackColor;
}
private void button1_Click(object sender, EventArgs e)
{//设置应用程序背景颜色(在运行时编写用户设置)
if(this.colorDialog1.ShowDialog()==DialogResult.OK)
{
Properties.Settings.Default.MyBackColor = this.colorDialog1.Color;
Properties.Settings.Default.Save();
this.BackColor = Properties.Settings.Default.MyBackColor;
}
}
- 2022-06-22 05:36:16下载
- 积分:1
-
TMS320C6748各个接口外设所有标准源码程序 (亲测好使)
TMS320C6748各个接口外设所有标准源码程序 (亲测好使)
- 2022-07-16 14:39:18下载
- 积分:1