cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - New to the community? Learn how to post a question and get help from PTC and industry experts! X

Need help with Visual Basic routine in Excel to set locations in Creo Drawing

ptc-6064077
1-Visitor

Need help with Visual Basic routine in Excel to set locations in Creo Drawing

Hi, I've been working through the dark maze of the VBA API, and the documentation for running routines using the Excel VBA is as remarkably sparse. I am having difficulty trying to determine how to handle a CpfcPoint3D object in an Excel routine. I have VB examples; but, I'm unable to determine how to structure the same in Excel. Here is what I have in the Excel routine;

Dim location As CpfcPoint3D

Set location = New CpfcPoint3D

location.Set(0, 10.0)

location.Set(1, 10.0)

location.Set(2,0)

(Excel objects to the .Set method for a location array. But, this is the example for a VB routine)

This is an example from a VB routine (from the PTC VB API documentation);

Dim pointLoc As IpfcPoint3D

pointLoc = New CpfcPoint3D

pointLoc.Set(0, 200.0)

pointLoc.Set(1, 600.0)

pointLoc.Set(2, 0.0)

Is there any VB API guru that can tell me what I'm doing wrong with my own code?

Thx!


This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
0 REPLIES 0
Announcements


Top Tags