简体   繁体   中英

Auto-increment an value inside a column by clicking on the datagridview

I was wondering if there's a way you can code that with every click on the datagridview a value of one of my columns in my database auto-increments it's value by one.

I was making an c# videostore application and every time someone clicks on a movie in my datagrid the value in it's column ''clicks'' raises by one.

As commented: MSND website

They show you how to add the event handler and then take the value you want and play with it.

Hope it helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM