API Reference

Class

VisioShapeDataSchema

Namespace OfficeIMO.Visio
Assembly OfficeIMO.Visio
Modifiers sealed

Reusable Shape Data schema for applying consistent Visio Prop rows to shapes and connectors.

Inheritance

  • Object
  • VisioShapeDataSchema

Usage

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters

Constructors

Methods

public VisioShapeDataSchema Add(VisioShapeDataField field) #
Returns: VisioShapeDataSchema

Adds a preconfigured field to the schema.

Parameters

field OfficeIMO.Visio.VisioShapeDataField requiredposition: 0
Field to add.
ApplyTo 3 overloads
public IReadOnlyList<VisioShape> ApplyTo(IEnumerable<VisioShape> shapes, Boolean overwriteValues = false) #
Returns: IReadOnlyList<VisioShape>

Applies the schema to a shape.

Parameters

shape OfficeIMO.Visio.VisioShape requiredposition: 0
Shape to update.
overwriteValues System.Boolean = false optionalposition: 1
Whether schema defaults should replace existing values.
ApplyTo(OfficeIMO.Visio.VisioConnector connector, System.Boolean overwriteValues) #

Applies the schema to a connector.

Parameters

connector OfficeIMO.Visio.VisioConnector required
Connector to update.
overwriteValues System.Boolean required
Whether schema defaults should replace existing values.
ApplyTo(System.Collections.Generic.IEnumerable{OfficeIMO.Visio.VisioShape} shapes, System.Boolean overwriteValues) #

Applies the schema to a set of shapes.

Parameters

shapes System.Collections.Generic.IEnumerable{OfficeIMO.Visio.VisioShape} required
Shapes to update.
overwriteValues System.Boolean required
Whether schema defaults should replace existing values.
public IReadOnlyList<VisioConnector> ApplyToConnectors(IEnumerable<VisioConnector> connectors, Boolean overwriteValues = false) #
Returns: IReadOnlyList<VisioConnector>

Applies the schema to a set of connectors.

Parameters

connectors System.Collections.Generic.IEnumerable{OfficeIMO.Visio.VisioConnector} requiredposition: 0
Connectors to update.
overwriteValues System.Boolean = false optionalposition: 1
Whether schema defaults should replace existing values.
public static VisioShapeDataSchema Create() #
Returns: VisioShapeDataSchema

Creates an empty Shape Data schema.

public VisioShapeDataSchema Field(String name, String label = null, Nullable<VisioShapeDataType> type = null, String defaultValue = null, String prompt = null, String format = null, String sortKey = null, Boolean required = false, Nullable<Boolean> invisible = null, Nullable<Boolean> verify = null, Nullable<Boolean> dataLinked = null, IEnumerable<String> allowedValues = null) #
Returns: VisioShapeDataSchema

Adds a field to the schema.

Parameters

name System.String requiredposition: 0
Shape Data row name.
label System.String = null optionalposition: 1
Optional label shown in Visio's Shape Data window.
type System.Nullable{OfficeIMO.Visio.VisioShapeDataType} = null optionalposition: 2
Optional Shape Data type.
defaultValue System.String = null optionalposition: 3
Default value used when applying the schema to missing or overwritten fields.
prompt System.String = null optionalposition: 4
Optional help prompt.
format System.String = null optionalposition: 5
Optional format picture or list values.
sortKey System.String = null optionalposition: 6
Optional sort key used by Visio's Shape Data window.
required System.Boolean = false optionalposition: 7
Whether validation should require a non-empty value.
invisible System.Nullable{System.Boolean} = null optionalposition: 8
Whether the row is hidden in Visio's Shape Data window.
verify System.Nullable{System.Boolean} = null optionalposition: 9
Whether Visio should ask for the value when the shape is created, copied, or duplicated.
dataLinked System.Nullable{System.Boolean} = null optionalposition: 10
Whether this row is linked to an external data recordset.
allowedValues System.Collections.Generic.IEnumerable{System.String} = null optionalposition: 11
Optional allowed value list used by validation and list formats.
Validate 2 overloads
public IReadOnlyList<VisioShapeDataSchemaIssue> Validate(VisioConnector connector) #
Returns: IReadOnlyList<VisioShapeDataSchemaIssue>

Validates a shape against the schema.

Parameters

shape OfficeIMO.Visio.VisioShape requiredposition: 0
Shape to validate.
Validate(OfficeIMO.Visio.VisioConnector connector) #

Validates a connector against the schema.

Parameters

connector OfficeIMO.Visio.VisioConnector required
Connector to validate.

Properties

public IReadOnlyList<VisioShapeDataField> Fields { get; } #

Fields included in the schema.