Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

Datagridview + Enter key = Row down, Different column?

Avatar of memozebadua
memozebaduaFlag for United States of America asked on
.NET ProgrammingVisual Basic.NET
4 Comments1 Solution432 ViewsLast Modified:
Hi experts!

I have a problem with a datagrid. When the user ends modifying a cell data and presses Enter, it saves data to the database and the normal behavior of the datagrid is to select the next row but same column.
My datagridview does not do that. I have not been able to see why, I don'w know where I turned the wrong way.

I'll explain myself better:

I have a datagridview which I programatically fill with data, wait for the user to change an specific cell value (qty of order) and update database table and then fill the datagridview again with the new data (calculating final price).

I am currently using CellValueChanged for the database part, CellEndEdit to refill the datagridview, EditingControlShowing to be able to filter unwanted chars and Datagridview KeyUp to catch the Delete keycode.

My current query has a lot of unions, because the final user wants the datagridview list separated by product categories.

Any ideas?

Thank you, very much.
Avatar of Shahan Ayyub
Shahan AyyubFlag of Pakistan imageStaff Software Engineer

Our community of experts have been thoroughly vetted for their expertise and industry experience.

This problem has been solved!
Unlock 1 Answer and 4 Comments.
See Answers