Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Databinding to dataset doesn't work in some cases

Status
Not open for further replies.

xai999

Programmer
Apr 7, 2005
24
0
0
NL
I'm building an application to register some information in a SQL 2000 DB. I use several forms to input the data.
They are all derived from a single base class that takes care of some layout stuff and handles the default data operations. These include showing the data in a datagrid and displaying a toolbar with navigationbuttons and buttons to insert and delete records.
This works for all forms, except for one. This implicates that the baseclass I use is working properly.
On this one form, the databinding only works when editing records. When I insert a new record, the right values are shown in the controls, but when I edit any of the values, the changes don't have effect in the dataset.
Any suggestions on how to find out what is wrong are welcome.
 
I didn't give the complete information in the first post. Sorry.

I actually do the databiding on a usercontrol. Then the control is docked onto a panel and it works. But the control where it isn't working is actually placed on a wrapper form at design time and then the form is shown on top of the application.

And then silence smacks right in there...
... And it is loud!
 
Wow! I found the problem and I'm shocked!
It appears that I didn't setup some default values to correct values for the dataset. It's fine that stuff failes when used incorrectly.
I'm just very surprised I didn't get any errors. It appears that somewhere along the line exceptions in this area are catched. I'm not shure if this happens in the framework somewhere, or in my application. Maybe someone can confirm.

And then silence smacks right in there...
... And it is loud!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top