Version

ApplyPresetFromXml(String,Boolean) Method

Applies the Preset data to the UltraGrid. The Preset data contained in the target file must be stored in an XML format.
Syntax
'Declaration
 
Public Overloads Sub ApplyPresetFromXml( _
   ByVal fileName As String, _
   ByVal clearAllSettings As Boolean _
) 
public void ApplyPresetFromXml( 
   string fileName,
   bool clearAllSettings
)

Parameters

fileName
The file containing Preset data stored in an XML format.
clearAllSettings
Determines whether to clear all property settings which can be specified in a Preset file before applying the new settings.
Example
This snippet demonstrates how to apply the information contained in a Preset file at run-time.

Private Sub SetupGrid()
   If myPresetIsXML Then
      Me.ultraGrid1.ApplyPresetFromXml("myPreset.xml")
   Else
      Me.ultraGrid1.ApplyPresetFromBinary("myPreset.bin", False)
   End If
End Sub
private void SetupGrid()
{
	if( myPresetIsXML )
	{
		this.ultraGrid1.ApplyPresetFromXml( "myPreset.xml" );
	}
	else
	{
		this.ultraGrid1.ApplyPresetFromBinary( "myPreset.bin", false );
	}
}
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