摘要: 添加控件:Windows Media Player axWindowsMediaPlayer1.URL = @"D:\KuGou\张国荣 - 我 - 压轴 2000热情演唱会.mp3"; axWindowsMediaPlayer1.Ctlcontrols.play();信息来源:http://www.csharpwin.com/csharpspace/2928.shtml 阅读全文
posted @ 2013-03-28 01:40 混蛋程序员 阅读(280) 评论(0) 推荐(0) 编辑
摘要: string DateStr(DateTime timeToString) { string timeString = timeToString.ToString(); string cToString = ""; // char.IsNumber()是个系统函数,检测字符内的数是否为数字 foreach (char timeToC in timeString) { if (!char.IsNumber(timeToC)) ... 阅读全文
posted @ 2013-03-02 15:48 混蛋程序员 阅读(4846) 评论(0) 推荐(0) 编辑
摘要: create PROCEDURE [dbo].[Pr_inportEasy_updateORinsert] @P1 varchar(20), @P2 varchar(20), @p3 intAS --创建if EXISTS(select * from inportEasy WHERE inportbName = @P1 and typeI = @P2) begin update inportEasy set quantity = quantity + @p3 WHERE inportbName = @P1 and typeI = @P2 --如果存在就更新 ... 阅读全文
posted @ 2013-02-10 18:26 混蛋程序员 阅读(368) 评论(0) 推荐(0) 编辑
摘要: create trigger T_ComputerNewUpdateChassis on [dbo].[computerNew]for insertas update dbo.inport set quantity = quantity - 1where inportName = (select Chassis from inserted)这是一个插入触发器。这句的语句大意是:但此表插入语句,另外一个表与之相应的项就会减少1参考来自:http://blog.csdn.net/wangboxian/article/details/7303474 阅读全文
posted @ 2013-02-10 16:32 混蛋程序员 阅读(176) 评论(0) 推荐(0) 编辑
摘要: 设置窗体属性KeyPreview=True。private void Form1_KeyUp(object sender, KeyEventArgs e){ if (e.KeyData == Keys.Escape)Application.Exit();}来自:http://zhidao.baidu.com/question/17393332.html 阅读全文
posted @ 2013-01-12 19:33 混蛋程序员 阅读(810) 评论(0) 推荐(0) 编辑
摘要: .ToString().TrimEnd('.','0')来自:http://zhidao.baidu.com/question/241077663.html 阅读全文
posted @ 2013-01-09 20:14 混蛋程序员 阅读(952) 评论(0) 推荐(0) 编辑
摘要: SqlConnection Conn=....//初始化,comboBox1绑定客户表string Sql= "select customerName from customer";DataSet Ds= new DataSet();SqlDataAdapter Da= new SqlDataAdapter(Sql, Conn);Da.Fill(Ds, "customer");comboBox1.DataSource = Ds.Tables["customer"];comboBox1.DisplayMember = "cus 阅读全文
posted @ 2013-01-07 15:40 混蛋程序员 阅读(485) 评论(0) 推荐(0) 编辑
摘要: private void frmMain_SizeChanged(object sender, EventArgs e) { FrmSell.Size = pnlShowFrm.Size; }设置form1的SizeChanged动作。 有缺憾:缩小不能同步,不知道如何更好做法。 阅读全文
posted @ 2013-01-06 03:38 混蛋程序员 阅读(424) 评论(0) 推荐(0) 编辑
摘要: this.panel1.Controls.Clear();//在加载控件时 先清空容器。 Form2 Frm = new Form2(); Frm.TopLevel = false; //这个很重要 。 this.panel1.Controls.Add(Frm); Frm.Show();来自:http://zhidao.baidu.com/question/237684416.html 阅读全文
posted @ 2012-12-30 23:57 混蛋程序员 阅读(445) 评论(0) 推荐(0) 编辑
摘要: 我这里是要比较button的图片是哪一个?(有两个流),然后问了人是要使用流来比较,以下是他给我的参考,来自:http://blog.csdn.net/eryongyan/article/details/6608355使用命名空间:using System.IO;private bool Same(Image image1, Image image2) { MemoryStream ms1 = new MemoryStream(); MemoryStream ms2 = new MemoryStream(); im... 阅读全文
posted @ 2012-12-30 21:57 混蛋程序员 阅读(2314) 评论(0) 推荐(0) 编辑