1 this.Invalidate();//重绘整个界面

2 触发键盘事件需要:fomr1 属性 keyPreview 这个要设为True

3 C#中设置ComboBox控件为不可编辑状态

(程序加载时候加入)

comboBox1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;

4 删除list集合中的元素

publict List DeleteList(List List)
{
foreach(List L in List)
{
if(L满足特定元素)

{
List.remove(L);
return DeleteList(List);
}

}
}

5 this关键字

6 this.panel1.Cursor = Cursors.Cross;

7 GDI绘图由于使用多种图形可以定义一个父类,定义父类类型的变量,来接受不同的子类

posted on 2015-08-03 18:17  lvsally  阅读(104)  评论(0编辑  收藏  举报