Datagrid won't update to the database?

al4629740
al4629740 used Ask the Experts™
on
I have a datagrid in vb6.  It is accessing an SQL Express 2005 database.  In the database I have a column that totals some of the other columns.

When I pull up that table in the datagrid, I normally enter numerical values in the columns.  The problem is that when I enter it and then move to the next row, the Total column does not automatically update.  However, if I look at the DB at the same time, I can see it is certainly adding.  The problem is that it is clearly not updating to the datagrid.  

If I retrieve the values from the whole grid then it updates the Total column, but I would rather like to see it update without having to do that.  Any suggestions?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

good morning!

it will happen because the datagrid is binded to the database...

if u want to see it updating, u must rebind the datagrid everytime u made changes
on it...

game-master

Author

Commented:
Any code examples to do thatv

Author

Commented:
Any code examples to do thatv
Success in ‘20 With a Profitable Pricing Strategy

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Author

Commented:
Again, any examples on rebinding the database to the datagrid?


good afternoon!

please post ur code on retrieving data from the database to your datagrid...


game-master


have u try the DataGrid1.ReBind
after ur opertation...


game-master

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial