Materials.itemById Method

Parent Object: Materials
Defined in namespace "adsk::core" and the header file is <Core/Materials/Materials.h>

Description

Returns the Material by it's internal unique ID.

Syntax

"materials_var" is a variable referencing a Materials object.
returnValue = materials_var.itemById(id)
"materials_var" is a variable referencing a Materials object.

#include <Core/Materials/Materials.h>

returnValue = materials_var->itemById(id);

Return Value

Type Description
Material Returns the specified material or null if there isn't a matching ID.

Parameters

Name Type Description
id string The ID of the material to return.

Version

Introduced in version August 2014