Текст метки не обновляется после обработки обновления строки gridview.
Мой dev express gridview имеет обработчик обновления строки, который, когда я пытаюсь изменить текст на метке, это изменение не отражается на экране. , Я тоже не получаю никакой ошибки.
<%@ Register Assembly="DevExpress.Web.v19.2, Version=19.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
Namespace="DevExpress.Web" TagPrefix="dxwgv" %>
df
<dxwgv:ASPxGridView ID="aspxgrdNotes" KeyFieldName="PoolItemNoteId" ClientInstanceName="grdNotes" OnRowUpdating="aspxgrdNotes_RowUpdating"
runat="server" AutoGenerateColumns="False" EnableRowsCache="false">
<SettingsCommandButton>
<EditButton ButtonType="Image" Text="Edit" Image-IconID="edit_edit_16x16" />
</SettingsCommandButton>
<Columns>
<dxwgv:GridViewDataTextColumn Caption="Id" FieldName="PoolItemNoteId" VisibleIndex="0" ReadOnly="true" CellStyle-Wrap="True" Width="100px" Visible="false"/>
<dxe:GridViewCommandColumn VisibleIndex="3" ShowEditButton="true" Caption="Edit"/>
<dxwgv:GridViewDataTextColumn Caption="Date" FieldName="NoteDate" VisibleIndex="2" ToolTip="Created Date"
ReadOnly="true" Width="100px">
<PropertiesTextEdit DisplayFormatString="{0:MM/dd/yyyy}" EncodeHtml="False">
</PropertiesTextEdit>
</dxwgv:GridViewDataTextColumn>
<dxwgv:GridViewDataTextColumn Caption="Note" FieldName="NoteText" VisibleIndex="2"
ReadOnly="false" CellStyle-Wrap="True" Width="600px">
</dxwgv:GridViewDataTextColumn>
</Columns>
<SettingsPager PageSize="25" ShowDefaultImages="False" Position="TopAndBottom">
<AllButton Text="All" />
<NextPageButton Text="Next >" />
<PrevPageButton Text="< Prev" />
</SettingsPager>
<Settings ShowFilterRow="true" ShowHeaderFilterButton="true" ShowGroupPanel="True" />
<SettingsBehavior AllowMultiSelection="false" AllowGroup="true" />
<SettingsPager PageSize="25" ShowDefaultImages="False">
<AllButton Visible="true" Text="All" />
<FirstPageButton Visible="true" />
<LastPageButton Visible="true" />
<NextPageButton Text="Next >">
</NextPageButton>
<PrevPageButton Text="< Prev">
</PrevPageButton>
</SettingsPager>
<Templates>
<EmptyDataRow>
No notes entered for this pool item.
</EmptyDataRow>
</Templates>
</dxwgv:ASPxGridView>
<dxwgv:ASPxLabel runat="server" ID="lblErrMsg" Text="" ForeColor="DarkRed" Visible="false"></dxwgv:ASPxLabel>
код позади:
Protected Sub aspxgrdNotes_RowUpdating(sender As Object, e As DevExpress.Web.Data.ASPxDataUpdatingEventArgs) Handles aspxgrdNotes.RowUpdating
e.Cancel = True
Me.aspxgrdNotes.CancelEdit()
' Update note
Dim poolItemNote As New PoolItemNote
If poolItemNote.LoadByPrimaryKey(e.Keys("PoolItemNoteId")) Then
poolItemNote.NoteText = e.NewValues("NoteText")
poolItemNote.ModBy = ALGMembershipUser.UserName
poolItemNote.ModTime = DateTime.Now
poolItemNote.Save()
' Rebind the notes grid
BindJobDetailData()
Else
lblErrMsg.Text = "Error updating note. Try reloading the page."
lblErrMsg.Visible = True
End If
End Sub