Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Crash during Update when datagridview sorted
Message
General information
Forum:
ASP.NET
Category:
The Mere Mortals .NET Framework
Title:
Crash during Update when datagridview sorted
Environment versions
Environment:
C# 2.0
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Miscellaneous
Thread ID:
01221559
Message ID:
01221559
Views:
73
I have created a very simple app using the MM Business Maintenance template. The Parent table is linked to 1 child with multiple rows per parent. Navigating the parent in a grid correctly retrieves all the child records. Add/Editing/etc works fine.
If I click on the datagridview header of a column (to sort by that column), the navigation works properly but if I edit the parent and try to Save, the system crashes. Even though no changes were done to the child data, the SQL Profiler shows a SQL Update command to a record in the child table trying to replace the parent foreign key with a new value which happens to duplicate an existing primary key and crashes the system. None of the normal rule checking methods are called during the update so how is it happening? Is it a bug in my program, a fault with the framework or some "undocumented" .NET feature?
Next
Reply
Map
View

Click here to load this message in the networking platform