Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.


How to use Move boundary in FeatureScript - opMoveBoundary()

MichaelPascoeMichaelPascoe Member Posts: 1,740 PRO
edited April 29 in FeatureScript
I was having trouble finding how to use the Move boundary within FeatureScript. There is no OpMoveBoundary or OpExtend like you would expect. Here is how you can do it:

Import the extend FS from Onshapes STD at the start of your project.
// For move boundary
import(path : "12312312345abcabcabcdeff/6509fdce3abecacec8f38b8a/cffdc47ca3931d4c4d41ee51", version : "0e66a19d0a986e71c5d22df8");

Next, define the definition for the extend surface and call the function:
// Extend ends using move boundary
const extendSurfaceDefinitionLeft = {
     "entities" : leftEnd, // Query
     "tangentPropagation" : false, // Boolean
     "endCondition" : ExtendBoundingType.BLIND, // ExtendBoundingType
     "extendDistance" : definition.extensionLeft, // Length
     "oppositeDirection" : false, // Boolean
     "targetPart" : qNothing(), // Query
     "targetFace" : qNothing(), // Query
     "targetVertex" : qNothing(), // Query
     "maintainCurvature" : false // Boolean

extendSurface(context, id + "leftEndExtend", extendSurfaceDefinitionLeft);

Learn more about the Gospel of Christ  ( Here )

CADSharp  -  We make custom features and integrated Onshape apps!   cadsharp.com/featurescripts 💎


Sign In or Register to comment.