Using Creo Application Programming Interface


The Very long time passed when I wrote something about programming on my blog. At that period, I encountered many things in my life for example I found a new job and have chanced living location for a short time. I have begun to learn Creo because of my job On the other hand as time goes by I’m interesting in new Creo VB toolkit programming and when I have free time generally I have spare time on improving this skills which is regarding how I use it, connect between other products.

Now, I would you like to show you that How Integrated development Environment (IDE) can be recognized to Creo Application Programming Interface (API);

Let`s begin how to do this,

Step One

At first, you have to select creo parameters customization and have to be sure selected creo programming interface which will be implemented though reference. When you installing Creo software. (You can see following picture that what I mean)

 

Note: Of course before you install creo. You had already have to install Visual studio 2005 or higher version. I’m not going to show you now. how you can install VS. Sorry! 🙁 This is out of topic. You have to handle it by yourself 🙂

Step Two;

For your application to communicate with Creo Parametric, you must set the PRO_COMM_MSG_EXE environment variable to the full path of the executable, pro_comm_msg.exe. Typically, the path to the executable is <creo_loadpoint>\Common Files\<datecode>\<machine type>\obj\pro_comm_msg.exe, where machine type is i486_nt for 32-bit Windows and x86e_win64 for 64-bit Windows installations.

Step Three,

Registering the COM Server
To register the COM server, run the vb_api_register.bat file located at <creo_loadpoint>/Parametric/bin. To unregister the COM server, run the vb_api_unregister.bat file located at <creo_loadpoint>/Parametric/bin. After the COM server is registered with the system, whenever an application tries to access the types contained in this server the server starts automatically. By default, Windows starts services such as pfclscom.exe in the Windows system directory (c:\winnt\system_32). Because the server will also start new sessions of Creo Parametric from the process working directory, you may want to control the server run.

Setting Project References for the VB API

Set the reference to Creo Parametric VB API Type Library for Creo Parametric through your project. In the VBA environment set this reference as follows:
1. Click
Tools References.

2. Check the box for
Creo Parametric VB API Type Library for Creo Parametric as shown in the following figure.


In the VB.NET environment, set this reference as follows:

1. Click

Project Properties Add Reference COM.

2. Select

Creo Parametric VB API Type Library for Creo Parametric as shown in the following figure.


 
 

 
 


http://www.gokhansaman.com/wp-content/plugins/sociofluid/images/google_48.png http://www.gokhansaman.com/wp-content/plugins/sociofluid/images/myspace_48.png http://www.gokhansaman.com/wp-content/plugins/sociofluid/images/facebook_48.png http://www.gokhansaman.com/wp-content/plugins/sociofluid/images/yahoobuzz_48.png http://www.gokhansaman.com/wp-content/plugins/sociofluid/images/twitter_48.png

Using Creo Application Programming Interface” hakkında 1 yorum

  1. Geri izleme: PTC Creo Parametric - using VBA API from C++ - iChrome

Bir cevap yazın

E-posta hesabınız yayımlanmayacak. Gerekli alanlar * ile işaretlenmişlerdir

This site uses Akismet to reduce spam. Learn how your comment data is processed.