Version

NullText Property (UltraGridOverride)

Returns or sets the string displayed in cells with null values.
Syntax
'Declaration
 
Public Property NullText As String
public string NullText {get; set;}
Remarks
You can use this property to customize the text displayed to the user when a null value is present in a cell. For example, you may want the cell to display "(empty)" or "no value". The default setting for this property is "null".
Example
Following code sets NullText property on override and column.

Imports Infragistics.Shared
Imports Infragistics.Win
Imports Infragistics.Win.UltraWinGrid

  Private Sub Button21_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles button21.Click

      ' NullText property specifies the text that the UltraGrid displayes in cells when
      ' the underlying value is DBNull.
      Me.ultraGrid1.DisplayLayout.Override.NullText = "(Null)"

      ' You can override above grid-wide settings for a particular band by setting the
      ' the NullText property on the Override object of the band.
      Me.ultraGrid1.DisplayLayout.Bands(0).Override.NullText = "NULL"

      ' Forthermore, you can override above settings for an individual column by setting
      ' that column's NullText property.
      Me.ultraGrid1.DisplayLayout.Bands(0).Columns(1).NullText = "(No Data)"

  End Sub
using Infragistics.Shared;
using Infragistics.Win;
using Infragistics.Win.UltraWinGrid;
using System.Diagnostics;

private void button21_Click(object sender, System.EventArgs e)
{

	// NullText property specifies the text that the UltraGrid displayes in cells when
	// the underlying value is DBNull.
	this.ultraGrid1.DisplayLayout.Override.NullText = "(Null)";

	// You can override above grid-wide settings for a particular band by setting the
	// the NullText property on the Override object of the band.
	this.ultraGrid1.DisplayLayout.Bands[0].Override.NullText = "NULL";

	// Forthermore, you can override above settings for an individual column by setting
	// that column's NullText property.
	this.ultraGrid1.DisplayLayout.Bands[0].Columns[1].NullText = "(No Data)";

}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also