Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How we check for not empty dataset?
Message
 
 
À
09/09/2008 09:36:43
John Baird
Coatesville, Pennsylvanie, États-Unis
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
C# 3.0
OS:
Windows XP
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01345899
Message ID:
01346052
Vues:
13
>>Originally we were using SQLDataSource. The DeleteCommand was set to be "Update People set Deleted = 1" In RowDeleted event there was a special handling to show a message with a button to undelete.
>>
>>Since we switched to just DataSet for the GridView DataSource this functionality stopped working. My colleague added a code to delete a record in RowDeleting method using direct update of the data, but the code doesn't seem to work.
>>
>>My original idea was to set Grid DataSource to SQLDataSource and somehow "refresh" the underlying DataTable when we retrieve a new DataSet. However, I never figured out if this is doable and in the meantime my colleague changed approach to always set GridView datasource to the DataSet.
>
>
>Use the dataset as the datasource, but get the dataset by using a DataTableAdapter FillMethod. by using the table adapter, you have access to select, insert, update, and delete methods.

I see, we'll try to investigate this approach.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform