06 2017 档案
摘要://sss={"100"}。有两个花括号 string sss = string.Format("{{\"100\"}}", 100); //string.Format("{0,向(正为右,负为左)对齐的字符串长度}","展示的字符串"); string s = string.Format("{0...
阅读全文
摘要:1、 2、拷贝 3、当对单元格内容进行格式修改时,CellParsing事件比较好(如变成大些) 完!
阅读全文
摘要:添加列时,必须设置列的CellTemplate,否则应该报错! 一、只添加text样式 1 //每一列必须设置CellTemplate 2 //第一列 3 dataGridView1.Columns.Add(new DataGridViewColumn() {Name="name", HeaderT
阅读全文
摘要:设置dragEnter 设置DragDrop using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using Sys
阅读全文
摘要:private void listView1_MouseUp(object sender, MouseEventArgs e) { if (e.Button == MouseButtons.Right)//设置鼠标右键 { ListViewItem li=listView1.GetItemAt(e.X...
阅读全文
摘要:第一种办法: 将ListView的数据放入DataView中,设置DataView的Sort属性,然后将DataView中的内容在ListView中展示出来。 (1)初始化ListView,将ListView的数据存入DataTable中 (2)从DataTable中获得DataView (3)设置
阅读全文