-
Project/Convert line in FS
can FS use project/convert line?
-
Vector coordinates help
Hello all. My mortise and tenon script is still a WIP and I have ran into yet another problem. I am using the corner of a rectangle as the reference point for an skRectangle() function. Suppose the coordinates of the corner are (-50, 50)*mm in the x-z plane, and I want to put a point that is 10mm across and 5mm down, I…
-
question mark meaning
what does a question mark means in FS coding?
-
Does Onshape have an automatic constraint functionality similar to Inventor?
So, let's say you've got a complex .dwg that you just want to import because you're too lazy to simplify it... in Inventor you'd just autoconstrain the whole shebang and you're off to the fully-defined races... and can delete constraints as you need later on. Anything like that in Onshape, and if not, might it conceivably…
-
How do I get the FeatureScript Beams to recognize the new profiles that I creat?
I made a copy of the Beams script (named it FeatureScript ModifledBeams), Added the profile for 1" X 1" to the profile list, changed the "beamProfileTable" constant to "beamProfileTableMod" in both the beam profile and beam feature tabs. When I load the ModifledBeams into the document it does not show the 1X1. If I open…
-
ROUND CORNERS
How can i round the corners of skrectangle or closed sklinesegment?
-
help on evDistance
-
how can i write this in FS
dim len as integer len = 1
-
how to get dimension?
-
Use opBoolean() on all parts that contain a point
Hi how would I use opBoolean() to remove material from all parts that are touching a part? I have currently used qContainsPoint, with qEverything() as the subquery, then using qSubtraction() to filter out the part itself. This works in finding the correct parts, but when I use the variable I have assigned to these parts in…
-
Unable to fillet an existing object - Need help
Hi, I am unable to fillet an existing object, it always throws up errors and ive tried everything to get around this such as trying to draw arcs with lines so i wouldnt have to fillet after i extrude to no avail. Here is my code: var length = 100*millimeter; var depth = 50*millimeter; var width = 500*millimeter; var…
-
Use a vertex in skRectangle()
Hi, how could I use a vertex's coordinates as the "firstCorner" coordinates for an skRectangle() function? Am I right by thinking that it must be a 2d vector and I could get it since I am using evVertexPoint, I could use vertexPoint[0] etc., but that only works if the part is in the correct orientation? Thanks Lee Hesketh
-
paid featurescript functions
Hello, Nowadays, from day to day many new featurescript tools appear from OS users. I think it's a great thing, we can learn from each other a lot. But it seems some users made their tools as paid version in the future, but the tools sometimes contain so basic features - like creating curves from external point data -…
-
skRectangle error when part's rotated
Hi there. I have a script that generates mortice and tenon joinery however I have some problems. It works fine if the parts face that the tenon protrudes from is aligned with the x axis. The problem is when it aligns with the y axis. How I have got it to work so far is the user selects two adjacent faces and then the…
-
Get face that shares a vertex
Hello, I need a piece of code that gets a face that contains a specific vertex. I already have the vertex specified, I just need the face such that the vertex makes one of its corners. Any Ideas? Thanks Lee Hesketh
-
Select adjacent ends given two faces
Hi everyone. I need to query for the ends of a rectangle given the user selects two adjacent faces. How could I do this? Thanks Lee Hesketh
-
Parameter space vs World space when using evFaceTangentPlane
I'd like to modify @jon_sorrells' Curve Pattern FS to accept a reference surface. The intention is to maintain the position of seed features/bodies/faces relative to the face normal at each incremental point along a curve. The problem is I don't see a way to generate a normal vector at any given point on a surface.…
-
Create sketch in middle of part
Hi all. I have a script where the user selects a face, then using qConvexConnectedFaces twice to select the ends. I have then found the midpoint of each of those faces and used them to find the midpoint of the part. What I need to do is create a plane at that point parallel to the end faces and then create a sketch. How…
-
Splitting a wing into ribs on iterations.
Im not getting any errors but also not getting any results, the idea is to split a wing into ribs and delete the bits in between, however user can specify rib number and thickness etc... var halfrib=Ribthick/2; for (var i = intervals; i < Length; i += intervals)//outerloop for each rib { for (var j = -1; j == 1; j +=…
-
skfitspline
Hi, so I'm writing another script I copied
and pasted a bit of code form my other script: skFitSpline(sketch1,
"UpperSpline", { "points" : UpperCoordinates }); where: UpperCoordinates=[vector(1,0.0130)*meter, vector(0.95,0.0230)*meter, vector(0.9,0.0396)*meter, vector(0.8,0.0732)*meter, vector(0.7,0.1039)*meter,…
-
Featurescript: How to create a line between two points (vectors)
How do I create a line in FS between two points (vectors), not using sketch points? since line(point,direction) only offers a direction, would I need to calculate the direction somehow, and how would I do that?
-
FeatureScript: How to query (not in viewer!) points and lines to create planes?
I'd like to create a plane in FS using either: * three points which I create as variables, vector(x,y,z) * meter * a line (more or less an axis, since it seems infinite) created using line(point,direction) and a point how do I query these points and lines so that they can be used? Note that I want to query these in FS; not…
-
Get distance between midpoint of face and edge
Hi there. How would I get the distance between the midpoint of a selected face and an adjacent edge?
-
Plane Axis orientation
@ilya_baran Lets say you have created a plane "Plane 2" as shown below. now as you see the plane created in in the same axis orientation of the Global X and Y axis even tough I have used the edge of the extrude to define the rotating axis. I want the plane to be oriented in such a way that the axis system of "Plane 2"…
-
Multiple use for imported parts
Okay, I'm going to try and explain this to the best of my ability (<--Feel like I've said that before?? :/ ) So I have a profile that I am importing in to a FS..... easy enough... Then, I turn it in to a function. export enum sealantProfileID
{ annotation { "Name" : "1/16 inch" } F72Dq47pUtYbudg_0, annotation { "Name" :…
-
FeatureScript Extrude Help
I'm working on a new FeatureScript and could use a little help. Inside of the script, it is creating a sketch and then using the extrude function to create the feature. I'm using the 'extrude' function instead of 'opExtrude' because I also want the option of adding a draft to the feature at the same time. I want the user…
-
Rib FeatureScript Modification
Hey All, I've made a modification to the Rib FeatureScript and thought I'd share it with everyone. The original Rib feature worked great, but sometimes I need to create two ribs with a specific distance between a face of one rib and a face of another one. It's a lot easier to do this within the sketch for the ribs, so with…
-
Guidance on planeToWorld and auto placing
Hello everyone, I am building on the collaboration of the 'Table Creator' I'm taking it to a different level. This time I am building a wall and placing a picture on the wall. I have most of the code already written, but if you look at what it creates you'll see that the picture ends up out in space..... I know it has to…
-
Target Audience for Help files.
Hi folks. Firstly this is not meant to be a winge although it may come across as such. Sorry for that :) I think you're doing an excellent job with regards to tool tips in the regular interface. (Hover over a button an explanation comes up, hover for longer a deeper explanation is given.) I wonder if there is a way to…
-
Revisioning public Featurescript - Public/Private Versions in one document?
Hi folks. I'm sure this has been covered before but I can't find the post I was after. Sorry if it's old ground. (Question 1) Lets say I have a document containing a FS that I've made public that I now want to develop further. The workflow I envisioned was to have the latest stable revision made public, and with further…