Creates a new Visual with a visual of the type identified by visualTypeId
and adds it to the collection.
Namespace: Spotfire.Dxp.Application
Assembly: Spotfire.Dxp.Application (in Spotfire.Dxp.Application.dll) Version: 25.11.10401.3615 (25.11.10401.3615)
Syntax
C#
public Visual AddNew( TypeIdentifier visualTypeId )
Parameters
- visualTypeId
- Type: Spotfire.Dxp.Framework.DocumentModelTypeIdentifier
The visual type identifier.
Return Value
Type: VisualThe newly created Visual.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | If the visualTypeId is null. |
ArgumentException | If the visualTypeId is invalid. |
Examples
C#
BarChart chart = page.Visuals.AddNew(VisualTypeIdentifiers.BarChart).As<BarChart>();
Version Information
See Also