BINDINGSOURCE.ENDEDIT CAUSES "COLUMN DOES NOT ALLOW NULLS" ERROR


C

Cam

Hello All,

Dev Environment:
Visual Studio 2005 (VB.NET)
SQL Server 2005 database (SP1)

Problem:
I get a "Column does not allow nulls" error when I try to add a new record
using the binding navigator. I click on the Add (Plus) button, I type the
values and hit save. I get the error.

Project:
I created the datasets using the dataset designer. The forms somewhat match
the database relations. In other words, the database was setup to have
parent-child relations. The form I am working on now (and trying to add a
record) is one of the child tables.

The column it does not allow nulls is a foreign key of the child table
(form). It is the PK of the parent. I tried to set the value manually, but
got same error.

Me.POLICYDATASET.POLICYTASKOBJECT.NewPOLICYTASKOBJECTRow.PolicyBaseObjectID_PK = 4

Can I access the table right before the add and set the value manually?

Is there something fundamentally wrong with my process or design?

Please advise.
 
Ad

Advertisements

C

Cam

As an MSDN subscriber, it is my understanding that I will receive feedback
within two days. Is there a reason for the non-response?

Please adivse
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top