v4.0
Returns a ProjectItemCollection containing each ProjectItem object in the library.
/*
This example shows how to get the current material library and how
to enumerates all materials in the library.
*/
var oScene = Application.ActiveProject.ActiveScene;
var oMaterialLib = oScene.ActiveMaterialLibrary;
var oMaterials = oMaterialLib.Items;
for( var i=0; i<oMaterials.Count; i++ ) {
var omat = oMaterials(i);
Application.LogMessage( "The library: " + oMaterialLib.Name
+ " contains the material: " + omat.Name );
}
// Expected result:
//INFO : The library: DefaultLib contains the material: Scene_Material
|