Category Solids and parts, Object ProSolid

Function ProSolidMdlnameCreate


Description
Creates a new Creo Parametric object of the specified type, and initializes the ProSolid handle. Note: In Creo 3 this function does not support names longer than 31 characters. It will return PRO_TK_LINE_TOO_LONG for longer names. The support for ProMdlName will be added in a future release.
Replacement in Object TOOLKIT: pfcBaseSession::CreatePart
pfcBaseSession::CreateAssembly
Synopsis
#include <ProSolid.h>
ProErrorProSolidMdlnameCreate(
ProMdlName name
/* (In)
The name of the new object
*/
ProMdlfileType type
/* (In)
The solid type (PRO_PART or PRO_ASSEMBLY)
*/
ProSolid* p_handle
/* (Out)
The handle to initialize
*/
)
Returns
PRO_TK_NO_ERRORThe function successfully created the new object.
PRO_TK_BAD_INPUTSOne or more of the input arguments are invalid.
PRO_TK_E_FOUNDAn object of the specified name and type already exists.
PRO_TK_GENERAL_ERRORThe object could not be created.
PRO_TK_LINE_TOO_LONGName length of the new object is more than 31 chars.

Manual References:

  1. Pro/DEVELOP to Creo Toolkit Function Mapping: Equivalent Pro/DEVELOP Functions
  2. Core: Models and Model Items: Creating Models
  3. Core: Models and Model Items: Creating Models
  4. Core: Solids, Parts, and Materials: Creating a Solid
  5. Working with Multi-CAD Models Using Creo Unite: Functions that Support Multi-CAD Assemblies
  6. Working with Multi-CAD Models Using Creo Unite: Superseded Functions
  7. Working with Multi-CAD Models Using Creo Unite: Restrictions on Character Length for Multi-CAD Functions

Sample Code References:

  1. pt_examples ( TestDbms.c )
  2. pt_examples ( TestImportfeat.c )
  3. pt_examples ( UtilTree.c )
  4. pt_userguide ( UgInterfaceExport.c )