本示例定制行的预览文本。
C# | 复制代码 |
---|---|
using DevExpress.XtraGrid.Views.Grid; private void gridView1_CalcPreviewText(object sender, CalcPreviewTextEventArgs e) { e.PreviewText = "Item: " + e.PreviewText + "; Units: " + gridView1.GetRowCellDisplayText(e.RowHandle, _ gridView1.Columns["UnitsOnOrder"]) + "."; } |
Visual Basic | 复制代码 |
---|---|
Imports DevExpress.XtraGrid.Views.Grid Private Sub GridView1_CalcPreviewText(ByVal sender As System.Object, _ ByVal e As CalcPreviewTextEventArgs) Handles GridView1.CalcPreviewText e.PreviewText = "Item: " + e.PreviewText + "; Units: " + _ GridView1.GetRowCellDisplayText(e.RowHandle, _ GridView1.Columns("UnitsOnOrder")) + "." End Sub |