PC Review
Forums
Newsgroups
Microsoft DotNet
Microsoft ADO .NET
How to alert to GridView
Forums
Newsgroups
Microsoft DotNet
Microsoft ADO .NET
How to alert to GridView
![]() |
How to alert to GridView |
|
|
Thread Tools | Rate Thread |
|
|
#1 |
|
Guest
Posts: n/a
|
I use a GridView to connection to a TableAdapter by a ObjectDataSource
and I add a partial calss to the TableAdapter, and add a new update method like: ----------------------------------------------------------------------- public virtual int Update2(int Pred, ..) { if (Some Conndition) return 0; else return Update(...) } ---------------------------------------------------------------------------- In some condition, it will update no row. How can I alert to the gridview that no row updated? I have try protected void gvSt_RowUpdated(object sender, GridViewUpdatedEventArgs e) { if (e.AffectedRows < 1) Label1.Text="®æ¦¡¿ù»~!!"; } But the e.AffectedRows always return -1 whether the row updated or not |
|
![]() |
|
| Thread Tools | |
| Rate This Thread | |
|
|

Main Page 

