AddParallelByDistance in Part

 

Hi all,

i want to add a parallel referenceplane to an existing referenceplane in the part-environment.

I use vb.net 2005

This code does not work.  Nothing happens. I don´t know why!

 

 

Sub Main()Dim seApp As SolidEdgeFramework.ApplicationDim objDoc As SolidEdgePart.PartDocumentDim refPlanes As SolidEdgePart.RefPlanesDim refPlane As SolidEdgePart.RefPlane"SolidEdge.Application")EndSub

 

 

 

 

 

seApp = GetObject(,

objDoc = seApp.ActiveDocument

refPlanes = objDoc.RefPlanes

refPlane = refPlanes.AddParallelByDistance(refPlanes.Item(1), 0.05, SolidEdgePart.ReferenceElementConstants.igNormalSide)

 

 

 

Posted by: Martin Rendler
Post date: 10/22/2009 3:13:18 AM

2 REPLIES

RE: AddParallelByDistance in Part

 

 

Hi all,

excuse the bad display of my code.

my code again

Dim seApp as SolidEdgeFramework.Application

Dim objDoc as SolidEdgePart.PartDocument

Dim refPlanes as SolidEdgePart.RefPlanes

Dim refPlane as SolidEdgePart.Refplane

seApp = GetObject (, "SolidEdge.Application")

objdoc = seApp.ActiveDocument

refplanes = objdoc.RefPlanes

refPlane = refPlanes.addParallelByDistance(refPlanes.item(1),0.05,SolidEdgePart.ReferenceElementConstants.igNormalSide)

 

 

 

 

 

 

Posted by: Martin Rendler
Post date: 10/22/2009 3:22:27 AM

RE: AddParallelByDistance in Part

Hi Nitram,

 

your code creates a "local" reference plane. This local reference plane is never visible.

To create a visible reference plane (that is changeable interactively) change your code like this:

 

refPlane = refPlanes.AddParallelByDistance(ParentPlane:=refPlanes.Item(1), _

Distance:=0.05, NormalSide:=SolidEdgePart.ReferenceElementConstants.igNormalSide, _

Local:=False)

 

 

 

Posted by: Herbert Goletz
Post date: 10/23/2009 1:21:42 AM