Jan 03, 2012 01:09 AM|Willi1972|LINK
Hi and thanks for the response,
the primary key for the StudentSubject table is a compound key using StudentID, Subject, ReportYear and ReportSession. In the DataKeyNames, I have left this blank, as the primary keys are all visible in the gridview - IIRC this means I don't need them in
I have been experimenting and I found that if I recreated the gridview from scratch, it would work (with nothing in DataKeyNames). However, when I tried moving some of the columns in the gridview, it broke it. More specifically, there is one field (ReportSession)
which stops the gridview from updating if it is moved beyond the 14th column. I also tried adding the keys to DataKeyNames, but this also stopped the gridview from updating.
This has really got me stumped!