I’m using Entity Framework in asp.net in Visual Studio 2012. I’m just learning these stuffs. I followed this tutorial
Just created the grid and I run the web site, everything is fine except the delete operation. When I click delete it shows me an error like this:

Would somebody tell me why I’m getting this error and how to rectify this. . .
Thanks in advance
Your answer for your question is given in your tutorial. (Applicable only if you are using the same tables and same constraints)
under “Revising EntityDataSource Control Markup to Improve Performance“
You are getting referential error means you haven’t used cascade in delete operation so when you delete a row in person table,as the same column is referenced in student grade table. so delete won’t take place. use cascade – ON DELETE CASCADE.