Skip to main content
1-Visitor
Apr 25, 2018 7:20 PM UTC
Question

How to insert UDF with jlink

Hello

 

I need some guidance on how to install an UDF into a part.

I have the UDF into a file. I cant seem to set the name of the UDF file to the object of type UDFCustomCreateInstructions.

Which is the command that should indicate which UDF should be inserted?

Secondly, I have the axis and plane datums that should be set as references and I am not sure which is the correct way to set the references.

Any suggestion or example is welcome.

 

Thank you

Regards

 

  

7 replies

HamsterNL
18-Opal
Apr 26, 2018 3:13 PM UTC

There are multiple examples in the jlinkug which should be available to you in your install directory of Creo.

 

Anyway, your UDFCustomCreateInstructions should look something like this:

 

UDFCustomCreateInstructions instrs = pfcUDFCreate.UDFCustomCreateInstructions_Create ("hole_quadrant");
Translate
vjoer1-VisitorAuthor
1-Visitor
Apr 26, 2018 7:33 PM UTC

Hello

 

Thank you for your aswer.

 

I am aware of the example in the install directory. And still I havent found all the info I need. 

For example, in your call, the "hole_quadrant" is the name of the UDF file? How do I specify a full path to the UDF file?

 

Regards

 

Translate
HamsterNL
18-Opal
Apr 28, 2018 5:36 AM UTC

A UDF is either in the current directory, or you could have a UDF Library (specify the directory with the configuration file option "pro_group_dir".

 

About Creating a UDF Library

Translate