| |

VerySource

 Forgot password?
 Register
Search
View: 1064|Reply: 9

SOLVED !!! How to make a cell in Datagridview edited ??? (in winform)

[Copy link]

2

Threads

2

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-2-14 23:30:01
| Show all posts |Read mode
Now has the DataGridview control dgv_mannage_goods,
I now want to stop the cursor in a cell when the window loads?
Reply

Use magic Report

4

Threads

12

Posts

12.00

Credits

Newbie

Rank: 1

Credits
12.00

 China

Post time: 2020-6-30 21:45:01
| Show all posts
The content after loading is uncertain, can not be positioned arbitrarily
Reply

Use magic Report

1

Threads

31

Posts

22.00

Credits

Newbie

Rank: 1

Credits
22.00

 Japan

Post time: 2020-8-11 13:30:01
| Show all posts
The following is an example:
this.dataGridView1.CurrentCell = this.dataGridView1[2, 2];
this.dataGridView1.BeginEdit(true);
Reply

Use magic Report

1

Threads

31

Posts

22.00

Credits

Newbie

Rank: 1

Credits
22.00

 China

Post time: 2020-8-11 13:45:01
| Show all posts
Hehe, it's all the same
Reply

Use magic Report

0

Threads

4

Posts

4.00

Credits

Newbie

Rank: 1

Credits
4.00

 China

Post time: 2020-8-11 14:15:01
| Show all posts
You can try to set the EditItemIndex property of the DataGridview control to the row you want to edit.

If it doesn't work, tell me again.
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-11 15:30:02
| Show all posts
dgvSubMenu.Columns[1].ReadOnly = false;
            dgvSubMenu.Columns[3].ReadOnly = false;
Reply

Use magic Report

1

Threads

2

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 China

Post time: 2020-8-13 22:45:01
| Show all posts
dataGridView1.CurrentCell = dataGridView1[1, 1];
dataGridView1.BeginEdit(true);
Reply

Use magic Report

0

Threads

3

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-21 14:30:01
| Show all posts
this.dataGridView1.CurrentCell = this.dataGridView1[2, 2];
this.dataGridView1.BeginEdit(true);
Reply

Use magic Report

0

Threads

2

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-21 15:00:01
| Show all posts
this.dgv_mannage_goods.CurrentCell = this.dataGridView1.Rows[0].Cells[0];
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-21 15:30:01
| Show all posts
this.dataGridView1.CurrentCell = this.dataGridView1.Rows[0].Cells[0];
this.dataGridView1.BeginEdit(true);
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list