Category Creo Parametric fundamentals, Object ProUnit

Function ProUnitInitByExpression


Description
Returns a ProUnititem given a unit-based expression, like "N/m2".
Replacement in Object TOOLKIT: pfcSolid::GetUnit
pfcMaterial::SetPropertyValue
pfcMaterial::SetPropertyUnits
Synopsis
#include <ProMdlUnits.h>
ProErrorProUnitInitByExpression(
ProMdl mdl
/* (In)
The model owning the units.
*/
ProPath expression
/* (In)
The unit expression.
*/
ProUnititem* unit
/* (Out)
The unit item.
*/
)
Returns
PRO_TK_NO_ERRORThe function succeeded.
PRO_TK_BAD_INPUTSOne or more arguments wasinvalid.
PRO_TK_GENERAL_ERRORThe expression cannot be parsed.

Manual References:

  1. Core: Solids, Parts, and Materials: Solid Units
  2. Core: Solids, Parts, and Materials: Solid Units
  3. Core: Solids, Parts, and Materials: Material Types and Properties