Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
RowFilter error when no rows match condition
Message
De
14/02/2009 10:56:55
 
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
C# 2.0
OS:
Windows Server 2003
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Desktop
Divers
Thread ID:
01380711
Message ID:
01381755
Vues:
21
>I am trying to use the DataTable.Dataview.RowFilter with users selecting from a variety of criteria and the program building the RowFilter expression. When the filter conditions results in no matching rows, I get a System.IndexOutOfRange exception. What do I need to do to trap this error? Thanks.
>
>Nevermind. I found what I needed. I set the DataTable.DataView.RowStateFilter to DataViewRowState.ModifiedCurrent and that eliminated the error.



That's an interesting solution Linda. How were you using your DataView? By that I mean, what control(s) was it bound to? I'm just curious ...

~~Bonnie
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform