Go to: Synopsis. Return value. Related. MEL examples.

Synopsis

setCustomAttrEnumResource(string $nodeType, string $attrLongName, int $enumIndex, string $str)

Convenience routine to define localizable string resource values for a custom attribute's enumerated values.

Return value

None

Related

loadPluginLanguageResources, setAttrNiceNameResource, setCustomAttrNiceNameResource, setNodeNiceNameResource

Arguments

Variable Name Variable Type Description
$nodeType string the node type
$attrLongName string the attribute's long name
$enumIndex string the index associated with the enum value (0, 1, 2, etc.)
$str string display string

MEL examples

  // Set the attribute enum strings associated with 
  // attribute "md" on node type "myNode".  
  // This example shows English resource values, however this 
  // routine would more often be called in practice to provide 
  // localized string values. 
  // 
        setCustomAttrEnumResource( "myNode", "md", 0, "Disabled");
        setCustomAttrEnumResource( "myNode", "md", 1, "Enabled");