100分求最小化像QQ样到桌面的右下角处方法 如题:我用的vs2003做了个winfrom程序;现在想把它运行时像点击QQ最下化时一样;托到桌面的最右下角处;有什么方法可以实现?????谢谢诶了 各位大虾;帮帮忙;急用;项目要交差了!!!!!!!!!!!(听说什么精灵可以实现{求方法!!!!!}) 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 notifyicon this.hide() this.show() Form1.cs*****************************************************************using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.Diagnostics;namespace WindowsFormsApplication3{ public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void Form1_SizeChanged(object sender, EventArgs e) { if (this.WindowState == FormWindowState.Minimized) { this.Hide(); this.notifyIcon1.Visible = true; } } }}**************************************Form1.Designer.cs*************************************************namespace WindowsFormsApplication3{ partial class Form1 { /// <summary> /// 必需的设计器变量。 /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// 清理所有正在使用的资源。 /// </summary> /// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); } #region Windows 窗体设计器生成的代码 /// <summary> /// 设计器支持所需的方法 - 不要 /// 使用代码编辑器修改此方法的内容。 /// </summary> private void InitializeComponent() { this.components = new System.ComponentModel.Container(); System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1)); this.notifyIcon1 = new System.Windows.Forms.NotifyIcon(this.components); this.测试ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components); this.contextMenuStrip1.SuspendLayout(); this.SuspendLayout(); // // notifyIcon1 // this.notifyIcon1.ContextMenuStrip = this.contextMenuStrip1; this.notifyIcon1.Icon = ((System.Drawing.Icon)(resources.GetObject("notifyIcon1.Icon"))); this.notifyIcon1.Text = "notifyIcon1"; this.notifyIcon1.Visible = true; // // 测试ToolStripMenuItem // this.测试ToolStripMenuItem.Name = "测试ToolStripMenuItem"; this.测试ToolStripMenuItem.Size = new System.Drawing.Size(100, 22); this.测试ToolStripMenuItem.Text = "测试"; // // contextMenuStrip1 // this.contextMenuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.测试ToolStripMenuItem}); this.contextMenuStrip1.Name = "contextMenuStrip1"; this.contextMenuStrip1.Size = new System.Drawing.Size(101, 26); // // Form1 // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(284, 262); this.Name = "Form1"; this.Text = "Form1"; this.SizeChanged += new System.EventHandler(this.Form1_SizeChanged); this.contextMenuStrip1.ResumeLayout(false); this.ResumeLayout(false); } #endregion private System.Windows.Forms.NotifyIcon notifyIcon1; private System.Windows.Forms.ContextMenuStrip contextMenuStrip1; private System.Windows.Forms.ToolStripMenuItem 测试ToolStripMenuItem; }} BS做不到。浏览器一关什么都没了。要是BS能做,那么那些搞广告的网站站长得高兴死了。 BS的可以;因为我们公司用的OA就行;主要是有一个图标;点击一个图标就行了;好像是什么A6 精灵; C# 调用树状菜单问题 TextBox的输入控制 扫雷游戏中的概率问题 求助sqlconnection问题 运行wcf例子急不稳定,时而成功,时而失败,帮我分析下原因吧 动态添加的dateTimePicker如何赋值 C#使用水晶报表问题 关于用 adapter对数据库进行更新的问题 z Crystal Report 如何自定义纸张大小? C# 分割字符串 新人求助:关于dll的调用
this.hide()
this.show()
*****************************************************************using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Diagnostics;namespace WindowsFormsApplication3
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
} private void Form1_SizeChanged(object sender, EventArgs e)
{
if (this.WindowState == FormWindowState.Minimized)
{
this.Hide();
this.notifyIcon1.Visible = true;
} } }
}
**************************************
Form1.Designer.cs*************************************************
namespace WindowsFormsApplication3
{
partial class Form1
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null; /// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
} #region Windows 窗体设计器生成的代码 /// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));
this.notifyIcon1 = new System.Windows.Forms.NotifyIcon(this.components);
this.测试ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components);
this.contextMenuStrip1.SuspendLayout();
this.SuspendLayout();
//
// notifyIcon1
//
this.notifyIcon1.ContextMenuStrip = this.contextMenuStrip1;
this.notifyIcon1.Icon = ((System.Drawing.Icon)(resources.GetObject("notifyIcon1.Icon")));
this.notifyIcon1.Text = "notifyIcon1";
this.notifyIcon1.Visible = true;
//
// 测试ToolStripMenuItem
//
this.测试ToolStripMenuItem.Name = "测试ToolStripMenuItem";
this.测试ToolStripMenuItem.Size = new System.Drawing.Size(100, 22);
this.测试ToolStripMenuItem.Text = "测试";
//
// contextMenuStrip1
//
this.contextMenuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.测试ToolStripMenuItem});
this.contextMenuStrip1.Name = "contextMenuStrip1";
this.contextMenuStrip1.Size = new System.Drawing.Size(101, 26);
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(284, 262);
this.Name = "Form1";
this.Text = "Form1";
this.SizeChanged += new System.EventHandler(this.Form1_SizeChanged);
this.contextMenuStrip1.ResumeLayout(false);
this.ResumeLayout(false); } #endregion private System.Windows.Forms.NotifyIcon notifyIcon1;
private System.Windows.Forms.ContextMenuStrip contextMenuStrip1;
private System.Windows.Forms.ToolStripMenuItem 测试ToolStripMenuItem;
}
}