Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error adding record when grid sorted
Message
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Titre:
Error adding record when grid sorted
Versions des environnements
Environment:
C# 2.0
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Divers
Thread ID:
01230520
Message ID:
01230520
Vues:
59
I have been trying for days to simply add a new record to the main business object without success and the problem seems to be related to whether or not the grid has been sorted before adding the record. In the sample C# Order App, I can select a customer and then add a new order without problems. If I sort the order grid on the OrderID column and add a record, I get the following error when saving:

"There is already an open DataReader associated with this Command which must be closed first."

After days or trying to debug this, I have given up. There are other problems that arise when the columns are sorted, such as positioning on the "last" row after adding a record but the last row will vary depending on the sorting column. When sorted on OrderID, the First row is the new record. When Not sorted, the Last row is the new record. This may be a trivial problem for an experienced .Net person but is causing me great problems. Can anyone help point me in the right direction?
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform