Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- 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.
Having troubles with: skCircle(Sketch, Id (array), map) does not match skCircle(..., string, ...)
darren_13
Member, Developers Posts: 119 PRO
the id: id+'circle1'+keys
debugs to: Id : [ "FIZxwPCJn00T9Nq_1" , "circle1" , "0" ]
I presume the issue is that it is an array of strings however this is valid for a sketch so I am puzzled. The link is: https://cad.onshape.com/documents/95877be3b17f49277e87a2c3/w/b503830fd20472014beb1221/e/4c4431103f44e823aca947dd
the feature script is 'Wing Structure Parametric' in folder 'Wing Structure Creator (prac)'
Thanks in advance,
Darren
debugs to: Id : [ "FIZxwPCJn00T9Nq_1" , "circle1" , "0" ]
I presume the issue is that it is an array of strings however this is valid for a sketch so I am puzzled. The link is: https://cad.onshape.com/documents/95877be3b17f49277e87a2c3/w/b503830fd20472014beb1221/e/4c4431103f44e823aca947dd
the feature script is 'Wing Structure Parametric' in folder 'Wing Structure Creator (prac)'
Thanks in advance,
Darren
Tagged:
0
Comments
In FS, the ~ operator joins values as strings, so you'll probably want to use something like id ~ 'circle1' ~ keys
e.g. It is valid to do something like:
var sketch = newSketchOnPlane(context, id + "sketch1,..)
for (var i = 0; i < 5; i += 1)
{
skCircle(sketch, "circle_" ~ i, ..);
}
skSolve(sketch);
sketch = newSketchOnPlane(context, id + "sketch2,..);
skCircle(sketch, "circle_1", '..)
skSolve(sketch);