VS:AddLevelFromTemplate

From Vectorworks Developer
Revision as of 14:35, 18 September 2014 by Root (talk | contribs) (1 revision: vw2015)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

.VectorScript|VectorScript ..VS:Function Reference|Function Reference ..VS:Function_Reference_Appendix|Appendix

Description

Adds a new Story Layer to the Story pointed to by 'storyHandle', using the Story Level Template at 'index' as a template. The story must not already contain a Story Level with the same level type or elevation as the template. If the template has a layer name set, a new layer will be created and associated with the new Story Level.

FUNCTION AddLevelFromTemplate(
storyHandle :HANDLE;
index :INTEGER) : BOOLEAN;
def vs.AddLevelFromTemplate(storyHandle, index):
    return BOOLEAN

Parameters

storyHandle HANDLE The handle of the Story to add the new Story Level to.
index INTEGER The index of the Story Level Template to use when creating the Story Level.

Return Value

Whether the Story Level was successfully created.

Example

VAR

storyHandle : HANDLE
success:BOOLEAN

BEGIN

storyHandle := CreateStory('Floor 1', '-1');
success := AddLevelFromTemplate(storyHandle,1);

Version

Availability: from Vectorworks 2015

See Also

VS Functions:

VS:CreateStory | VS:AddStoryLevel | VS:RemoveStoryLevel | VS:SetLevelElevation | VS:GetLevelElevation

VS Functions:

[[VS:CreateStory]] | [[VS:AddStoryLevel]] | [[VS:RemoveStoryLevel]] | [[VS:SetLevelElevation]]

| [[VS:GetLevelElevation]]