470,586 Members | 1,651 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,586 developers. It's quick & easy.

ForeignKeyConstraint StudentsSchYrSem requires the child key values (21000013) to exist in the parent table

I have created 3 sqldataadapter. each adapter.selectcommand has a
parameter. I have added a textbox to supply a value for each
parameter. My problem is when I press enter the second time to fire up
the keypress event from the textbox I recieved this error in datagrid
object "ForeignKeyConstraint StudentsSchYrSem requires the child key
values (21000013) to exist in the parent table"

I'm wondering before if I change the value of that textbox only the
second time have an error.

The parameter is lastname.
example if I provide a value in the textbox the first time and press
enter i did not recieve an error. the second time i change the value
of a textbox gives me an error. after that no error has occur.

seems this is a very strange error to me.
Nov 21 '05 #1
1 2539
Never mind. I have already solved the problem. The problem is that I
bind it two times in my code.
On Fri, 10 Dec 2004 12:16:12 +0800, jaYPee <hi******@yahoo.com> wrote:
I have created 3 sqldataadapter. each adapter.selectcommand has a
parameter. I have added a textbox to supply a value for each
parameter. My problem is when I press enter the second time to fire up
the keypress event from the textbox I recieved this error in datagrid
object "ForeignKeyConstraint StudentsSchYrSem requires the child key
values (21000013) to exist in the parent table"

I'm wondering before if I change the value of that textbox only the
second time have an error.

The parameter is lastname.
example if I provide a value in the textbox the first time and press
enter i did not recieve an error. the second time i change the value
of a textbox gives me an error. after that no error has occur.

seems this is a very strange error to me.


Nov 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by ahaideb | last post: by
reply views Thread by oj | last post: by
1 post views Thread by David A. Osborn | last post: by
5 posts views Thread by PAUL | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.