Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating a Script to Publish Geometry

Status
Not open for further replies.

CPosner

Mechanical
Jan 26, 2007
139
I need to create a script to publish geometry.

I am having much trouble doing it and I need some tips. I have the code correct in terms of the help files and information, but it still will not work.


Dim Pub As Publications

Dim spline As Product 'gets product interface

Set spline = partDocument1.GetItem("Spline") 'part number

Set Pub = spline.Publications

Dim pub1 As Publication

Dim refp As Reference

For i = 1 To 10 Step 1


Set pub1 = Pub.Add("Point." & i)
Pub.SetDirect "Point." & i, reference2

Next i

It always fails on the "SetDirect" Command. I'm using VB Script and It's a RunTime error.

Any ideas.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor