
C#
司佳堡
这个作者很懒,什么都没留下…
展开
-
C# 循环遍历DataGridView获取所有数据(不包含HeaderText)
for(int i = 0;i < dataGridView1.RowCount; i++){ for(int j = 0;j < dataGridView1.ColumnCount; j++) { //打印第i行第j列数据 Console.WriteLine(Convert.ToString(dataGridView1.Rows[i].Cells[j].Value)); ...原创 2019-04-25 22:08:26 · 9743 阅读 · 1 评论 -
C# 关于JArray和JObject封装JSON对象
目标是构造下面这个形式的json。[ { "id": "contest", "entity": { "contestId": { ... } }]JArray Modules = new JArray();JObject jp = new JObject(new JProper...原创 2019-04-30 17:44:10 · 857 阅读 · 0 评论 -
C# 从json中判断某个属性是否存在
{ "lang": [], "modules": [ { "id": "user_table", "entity": { "id": { "visible": true, "createable": true, "type": "int(11)" }, ...原创 2019-05-06 21:48:58 · 9486 阅读 · 1 评论 -
C# 清空dataGridView的数据
表格中的数据是自己填写的,不是绑定数据源。int count = dataGridView1.RowCount;if(count > 0){ for(int i = 0;i < count; i++){ dataGridView1.Rows.Clear(); }}原创 2019-05-07 15:48:12 · 5958 阅读 · 2 评论