Removes a Simple material from a Compound material.
FUNCTION RemoveSubMtrlFromMtl(
hMaterial : HANDLE;
subMtrlName : STRING): Boolean;def vs.RemoveSubMtrlFromMtl(hMaterial, subMtrlName):
return Boolean| Name | Type | Description |
|---|---|---|
| hMaterial | HANDLE | Handle of a Compound material |
| subMtrlName | STRING | Name of a Simple material to be deleted |
resultOK := RemoveSubMtrlFromMtl(hMaterial, 'Example');import vs
# Removes a Simple material from a Compound material.
hMaterial = vs.FSActLayer() # handle to the first selected object on the active layer
subMtrlName = 'Example'
ok = vs.RemoveSubMtrlFromMtl(hMaterial, subMtrlName)
if ok:
vs.Message('RemoveSubMtrlFromMtl succeeded')
else:
vs.Message('RemoveSubMtrlFromMtl failed')Availability: from Vectorworks 2021