RunNewFSObjectDialog (open)

Run the 'create new object' flow

Syntax

LOADLIB "mod::publisher/lib/dialogs.whlib";

INTEGER FUNCTION RunNewFSObjectDialog(OBJECT parentscreen, INTEGER parentfolder, RECORD options)

Parameters

OBJECT parentscreen

Screen invoking us

INTEGER parentfolder

Folder which will receive the new object

RECORD options

Options

BOOLEAN isfolder

If true, create a folder

BOOLEAN issite

If true, create a site

INTEGER ARRAY limittypes

If set, allow only templates and types with one of these IDs to be added

INTEGER template

If not 0, duplicate this object. (isfolder and type options are ignored)

INTEGER type

Type to create. If not set, this flow may launch a 'select type' dialog

Return value

INTEGER

ID of the newly generated fsobject, 0 if creation was cancelled

Description

This function invokes the standard 'new object' flow (which currently starts with a type selection and then runs the objectproperties dialog)