Creo Toolkit Guide

Creo TOOLKIT is the C-language customization toolkit for Creo Parametric. It enables customers and third parties to expand Creo Parametric capabilities by writing C-language code and seamlessly integrating the resulting application into Creo ParametricCreo TOOLKIT provides an extensive library of C functions that enables the external application to access the Creo Parametric database and user interface in a controlled and safe manner.

Rating: 4.63
3878

 

Creo Toolkit Guide

 

Introduction

  • Creo Toolkit is an API (Application Development Interface) i.e a development library that enables to create applications that plug-in to Creo Parametric
  • Creo Toolkit as an API enables ultimately users to create runtime applications

Getting Started with Creo Toolkit

  • To have a start with Creo Parametric Customization APIs, users can refer and start with the Getting Started Guides and complete User Guide Documents
  • These Guides can also be accessed from the Creo Parametric installation folders as shown below if the respective customization component is included during installation.
    • Creo Load Point (CLP) : Install Directory of Creo
    • Common File (CF) : CLP\Common Files
    • Creo Load Point (CLP) : Install Directory of Creo
    • Creo Toolkit: Creo_Toolkit_GSG.pdf
    • Creo OTK C++: OTK_Cxx_GSG.pdf
    • Creo OTK Java: OTK_Java_GSG.pdf

Installing Creo Toolkit

For Pro/ENGINEER Wildfire & Creo Elements/Pro 5.0 releases:

  1. Start Pro/ENGINEER or Creo Elements/Pro 5.0 installation
  2. Expand API Toolkits under Features to install on Define Installation Components page.
  3. Select Pro/TOOLKIT and select Install this feature.
  4. Complete the installation.

For Creo Parametric releases:

  1. Start Creo Parametric installation
  2. Select Install or add new software > Next > Sign Software License Agreement > Next > Select appropriate license input method or type source. Once status is seen “Available” > Next
  3. Click on Customize… > In Application Custom Setting window, click on Creo Parametric option on the left hand pane > In Application Features tab expand API Toolkits feature > Check option Creo Toolkit or PTC Creo Parametric TOOLKIT as shown in below image > OK
  4. Click Install button to complete installation.

Creo Toolkit Install

  1. After successful installation, below listed folders will be observed in Creo Parametric Installation Folder:
  2. Please refer to Topic Installing Creo Parametric TOOLKIT under Creo Parametric TOOLKIT User’s Guide Chapter Fundamentals for more detailed information on the contents of these folders.
  3. If Creo installation folder is C:\Program Files\PTC\Creo6.0.3.0\
  4. tk will be C:\Program Files\PTC\Creo6.0.3.0\Common Files\protoolkit
  5. <tk>\includes :- Contains all required C header files (*.h) necessary for TOOLKIT Application development.
  6. <tk>\protk_appls:- The directory protk_appls contains sample Creo Parametric TOOLKIT applications. For more information regarding the sample applications refer to the Appendix on Sample Applications in Creo Parametric TOOLKIT User’s Guide
  7. <tk>\protkdoc :- Contains Creo Parametric TOOLKIT API Wizard files.
  8. Launch Page is <tk>\protkdoc\index.html
  9. <tk>\x86e_win64\obj :- Platform Specific folder. Contains..
    1. Sample Make files: Example: make_basic, make_examples, make_install, make_install_cxx etc.
    2. Unlocked Sample Application Dlls: Example: pt_examples.dll, pt_userguide.dll, pt_inst_test.dll etc.
      • For more information, please refer to Creo Parametric TOOLKIT User’s Guide Chapter Creo Parametric TOOLKIT Sample Applications
    3. Static Libraries: Example: protoolkit_NU.lib, pt_asynchronous.lib, ucore.lib, udata.lib etc.
    4. protk_install_example.zip: Sample Make file based Visual Studio Project to compile pt_inst_test sample application
    5. pt_install_cxx.zip : Sample regular Visual Studio Project to compile pt_inst_test sample application.
  10. <tk>\Creo_Toolkit_GSG.pdf :-  PDF format Guide for Getting Started with Creo Parametric TOOLKIT
  11. <tk>\Creo_Toolkit_RelNotes.pdf :- Creo Parametric TOOLKIT Release Notes
  12. <tk>\tkuse.pdf :- PDF format of Creo Parametric TOOLKIT User’s Guide

What is the Creo Parametric TOOLKIT API, aka the Pro/TOOLKIT API?

  1. Provides customers and third-parties the ability to expand Creo Parametric capabilities by writing C programming language code and then seamlessly integrating the resulting application into Creo Parametric.
  2. Provides a large library of C functions to provide the external application safe and controlled access to the Creo Parametric database and applications.
  3. Creo Parametric TOOLKIT is the primary PTC application programmer’s interface (API) for Creo Parametric and requires certain License Modules.

Creo Toolkit Customization Possibilities

Scheme that represents the coverage of Toolkit API vs the existing Creo Parametric capabilities

Creo Toolkit Customization

  • The rule of thumb: Toolkit Support is likely when it can be performed from the User Interface (see above scheme)
  • Inversely, if something cannot be performed from Creo User Interface, then it is also not available in the API in Toolkit, Object Toolkit, weblink, VB API or Jlink / OTK Java Free
  • The API enables one to automate exclusively existing Creo UI commands
  • The Toolkit execution does however not necessarily mirror identical functionality, for example a functionality performed with one click on the UI may need several function calls
  • Creo Toolkit is no super mode of Creo with functions that would supersede what is possible from the UI

Creo Toolkit API Wizard

Toolkit API Wizard is available in the <path>. This provides the entire list of APIs available for Creo Toolkit functionalities

Determine which Toolkit API is available to achieve a specific functionality

  • Search in Creo Parametric TOOLKIT API Wizard. Launch Page available at <tk>\protkdoc\index.html
  • Open <tk>\protkdoc\index.html in a browser
  • Select Creo Parametric TOOLKIT: API Wizard
  • Use the search field at the top of the left pane to search for functions. Users can search using the following criteria:
    • Search by API names
    • Search using wildcard character *, where * (asterisk) matches zero or more nonwhite space characters
  • The search displays the resulting API names with embedded links in a drop-down list. The deprecated APIs are highlighted in yellow.
  • Use the below described Creo Toolkit naming convention to guess the required API name
    • Creo Parametric TOOLKIT functions are named as per below two conventions
      1. Pro + Object + Action
      2. Pro + Object + Property + Action
    • Example: Search and find the function name to save a given part / asm model
      1. As per the first naming convention rule, if we try guessing the possible function name for saving a model, it would be Pro + Model + Save (or store)
      2. Try the key words pro*save or pro*mdl*save
      3. Read the Description of the functions listed in the result.
      4. You will understand from the description that ProMdlSave() is the correct function to save a given model
      5. Similarly, try Pro*mdl*retrieve to find that the functions ProMdlRetrieve() & ProMdlnameRetrieve() can be used to Open a model in to Creo memory.
      6. Similarly try Pro*item*name*get to find that ProModelitemNameGet() can be used to Retrieve the name of the specified model item

Registry File for Creo Toolkit

  • Set protkdat option to your current session config.pro 
    • more about option protkdat with article
    • prodev.dat (deprecated), now replaced by creotk.dat or protk.dat
  • Store your protk.dat / registry file in one of the folders scanned by Creo at startup:
    • The Creo starting directory
    • <creo_loadpoint>\<datecode>\Common Files\$<machine_type>\text\<language>
    • <creo_loadpoint>\<datecode>\Common Files\text
    • <creo_loadpoint>\<datecode>\Common Files\text\<language>
    • %ProgramData%\PTC\<Creo version>\Plugins subdirectories
  • As a workaround, load the application manually by browsing: 
    • File > Tools > Auxiliary Application > Register > pick the .dat file

Conclusion

Creo Toolkit is a robust solution enabling Creo customers to implement and extend customized functionalities. With Creo Toolkit companies can significantly save time by automating repetitive, manual and quality sensitive tasks. Learn Creo Toolkit from PLM Coach and enhance your earning potential

Checkout our Other Resources

PLM Coach – All Courses

Teamcenter PLM Architecture

Learn CATIA CAA RADE

Teamcenter Functional Guide

3DEXPERIENCE Enterprise Knowledge Language

The Best PLM Guide

————————————————–

🌍 For PLM / CAD Training Visit ► https://plmcoach.com

Follow PLM Coach on Social Media:  

YouTube LinkedIn | 

Facebook | Twitter | Pinterest

📧 Contact PLM Coach:

Follow the link to Training Inquiry Form to provide your details

https://plmcoach.com/inquiry

Follow the link to Text PLM Coach on WhatsApp

https://wa.me/917989703878

☏ Mobile Number ► +91-7989703878

💌 Email ► info@plmcoach.com

————————————————–

About Author
Anup Karumanchi
Anup Karumanchi
Champion of PLM, CAD & MES platforms, with a proven track record of delivering successful workshops and services for global clientele.

Leave a Comment

Your email address will not be published. Required fields are marked *

Call us

Scroll to Top