VS:AddStoryLevel

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'. There must not be another story level in this story that matches 'levelType' or 'elevation', or the function will fail. If the layer 'layerName' already exists, it will be associated with the new Story Level.

FUNCTION AddStoryLevel(
storyHandle :HANDLE;
levelType :STRING;
elevation :REAL;
layerName :STRING) : BOOLEAN;
def vs.AddStoryLevel(storyHandle, levelType, elevation, layerName):
    return BOOLEAN

Parameters

storyHandle HANDLE The handle of the story that the new level should be added to.
levelType STRING The level type of the new Story Level. This cannot be blank.
elevation REAL The elevation of the new Story Level in the story.
layerName STRING The name of the layer to associate with the new Story Level. This is optional.

Return Value

Whether the new Story Level was created and added.

Example

VAR

storyHandle : HANDLE
success:BOOLEAN

BEGIN

storyHandle := CreateStory('Floor 1', '-1');
success := AddStoryLevel(storyHandle, 'Finish Floor', 0, 'Floor');

Version

Availability: from Vectorworks 2015

See Also

VS Functions:

VS:CreateStory | VS:AddLevelFromTemplate | VS:RemoveStoryLevel | VS:SetLevelElevation | VS:GetLevelElevation

VS Functions:

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

| [[VS:GetLevelElevation]]