GRAPHISOFT®

Python APIVersion: 0.23 Beta

ChangeZone

Modifies a Zone element.

def ChangeZone (element, memo) -> String

 

Parameters

element
[in] An APIObject describing the element to modify.
memo
[in] An APIObject containing the zone parameters. Only addPars is used.

 

Return Values

This function returns the GUID of the modified element.

 

Remarks

This function is analogous to the ACAPI_Element_Change function of the C++ API for Zone elements. By setting a member of the passed APIObject you also mask it for the operation.

For information on how to fill the passed APIObject, visit the C++ documentation.

 

Example


def ChangeZoneNumber (guid):
    element = GetZone (guid)
    count = 1
    element[0].roomNoStr = 'NEW No {}'.format(count)
    return ChangeZone (element, APIObject ())

for elemGuid in GetSelectedElements ():
    element = GetElement (elemGuid)
    typeID = GetElementType (elemGuid)
    if (typeID == API_ZoneID):
        ChangeZoneNumber (element)

 

Requirements

Version: Python API 0.1 or Later
Module: GS

 

See Also

GetZone

All functions