Using FS can we create a sketch on a face of a part or only on Planes?

owen_sparks
owen_sparks Member, Developers Posts: 2,660 PRO
Hi Folks.

I'm playing with my first FS.

Using FS can we create a sketch on a face of a part or only on Planes?

More broadly I have an input of a single vertex (from a sketch on the surface of a solid part).  I wish to create a sketch here then add some geometry to work with.

What's the easiest way to accomplish this please?  (The Slot Tutorial has us creating new planes but from a coordinate system and a line.  I just have a point to start with.)

Many thanks for your help,

Owen S.

Business Systems and Configuration Controller
HWM-Water Ltd

Best Answers

Answers

  • owen_sparks
    owen_sparks Member, Developers Posts: 2,660 PRO
    Hi Cody, thanks for the info.  That sounds perfect.

    Sorry to be a PITA but would you mind helping with the syntax?

    I have this in the precondition:-

    // Target Point(s)
                    annotation { "Name" : "Select Sketch Point(s)", "Filter" : EntityType.VERTEX, "MaxNumberOfPicks" : 1 }
                                   
                                    // or for unlimited picks
                                   
                    // annotation { "Name" : "Select Sketch Point(s)", "Filter" : EntityType.VERTEX  }
                       
                        definition.targetpoint is Query;

    ...and then later in the function:-

    var sketch2 = newSketch(context, id, {
                            "sketchPlane" : evOwnerSketchPlane(definition.targetpoint)
                    });

    which is incorrect, throwing the error "Function evOwnerSketchPlane with 1 argument(s) not found".

    What is the correct method to evaluate this point and use it to create the sketch?

    -----------------------------------------------------------------------------------------------------
    The help file tells us we can use a vertex:-

    evOwnerSketchPlane (context is Context, arg is map) returns Plane

    Return the plane of the sketch that created the given entity.

    ParameterTypeAdditional Info
    arg map
    • entity
    Query

    The sketch entity. May be a vertex, edge, face, or body.

    ------------------------------------------------------------------------------------------------------

    Many thanks,

    Owen S.






    Business Systems and Configuration Controller
    HWM-Water Ltd
  • owen_sparks
    owen_sparks Member, Developers Posts: 2,660 PRO
    Thanks Gents.

    Extra filter added to precondition and:-

    var sketch1 = newSketchOnPlane(context, id, {
                            "sketchPlane" : evOwnerSketchPlane(context, {
                                    "entity" : definition.targetpoint
                            })
                    });

    Did exactly what was required.

    Your help is appreciated :)

    Cheers,

    Owen S

    Business Systems and Configuration Controller
    HWM-Water Ltd