FavoriteMaterials.itemById Method

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

Description

Returns the Material by it's internal unique ID.

Syntax

"favoriteMaterials_var" is a variable referencing a FavoriteMaterials object.
returnValue = favoriteMaterials_var.itemById(id)
"favoriteMaterials_var" is a variable referencing a FavoriteMaterials object.

#include <Core/Materials/FavoriteMaterials.h>

returnValue = favoriteMaterials_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