ConvertContentType (open)

Convert contenttypes

Syntax

LOADLIB "mod::system/lib/migrations.whlib";

RECORD ARRAY FUNCTION ConvertContentType(STRING srctype, RECORD options)

Parameters

STRING srctype

Source instance type

RECORD options

Options

STRING desttype

Destination type. If empty, assumed to equal the source type

FUNCTION PTR mapcallback

Callback to invoke on instance records for conversion. If it returns a DEFAULT RECORD, this instance will not be converted

BOOLEAN sourceorphans

Open source type and data as an oprhan (access deleted types and members)

Return value

RECORD ARRAY

A list of fsobjects converted, suitable for passing into RepublishWHFSObjectReferences

INTEGER ARRAY fsobject

fsobject ID containing the instance

Description

Rewrite content types (and widgets) to the specified type. Instances (eg widgets in RTDs) of the source type will be changed to the destination type