Spreadsheet .Start.xyz, .End.xyz

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
User avatar
thomas-neemann
Veteran
Posts: 11801
Joined: Wed Jan 22, 2020 6:03 pm
Location: Osnabrück DE 🇩🇪
Contact:

Re: Spreadsheet .Start.xyz, .End.xyz

Post by thomas-neemann »

bgma1961 wrote: Tue May 24, 2022 10:28 am ...
I would try a 3D wireframe in Sketch. that can be varied easily. with walls, windows, doors and floors it gets very complicated
Bildschirmfoto_2022-05-24_12-54-20.png
Bildschirmfoto_2022-05-24_12-54-20.png (252.49 KiB) Viewed 632 times
Gruß Dipl.-Ing. (FH) Thomas Neemann

https://www.youtube.com/@thomasneemann5 ... ry=freecad
Workshop_Notes
Posts: 590
Joined: Wed Sep 29, 2021 8:35 am

Re: Spreadsheet .Start.xyz, .End.xyz

Post by Workshop_Notes »

bgma1961 wrote: Tue May 24, 2022 8:48 am No it does not work with <<Spreadsheet>> .B1 in "#Line.Base.Placement.Position.z".
I wonder whether 'Position' might be stored as a list or tuple (an array-like object).

In which case, can you try addressing its members by Position[0], Position[1] and Position[2]?

AIUI, .x, .y and .z notations are shorthand (macros?) for the more formal notation.

Probably won't work, but worth a try.

I take my inspiration for this from the way you reference constraints in sketcher.
User avatar
adrianinsaval
Veteran
Posts: 5541
Joined: Thu Apr 05, 2018 5:15 pm

Re: Spreadsheet .Start.xyz, .End.xyz

Post by adrianinsaval »

I get this error when recomputing but not always:

Code: Select all

Test7#Line still touched after recompute
The problem is that the Draft object changes the start and end values based on the placement so trying to force values on both at the same time creates a recomputation loop. This is either a bug in Draft or you are just not supposed to mess with the placement of Draft objects.
To workaround this I suggest you leave the placement at (0,0,0) without expressions and then use just the star and end points to control it.

@yorik thoughts? why does the placement of the draft line have an effect on the start and end points? If the points are meant to be absolute the placement should be immutable IMO.
bgma1961
Posts: 107
Joined: Mon Apr 02, 2018 9:19 am

Re: Spreadsheet .Start.xyz, .End.xyz

Post by bgma1961 »

adrianinsaval wrote: Tue May 24, 2022 2:15 pm I get this error when recomputing but not always:

Code: Select all

Test7#Line still touched after recompute
The problem is that the Draft object changes the start and end values based on the placement so trying to force values on both at the same time creates a recomputation loop. This is either a bug in Draft or you are just not supposed to mess with the placement of Draft objects.
To workaround this I suggest you leave the placement at (0,0,0) without expressions and then use just the star and end points to control it.

@yorik thoughts? why does the placement of the draft line have an effect on the start and end points? If the points are meant to be absolute the placement should be immutable IMO.
If it worked to use Placement, it would have been great ....
Since .Start.z and .End.z in this case should have the same value, it seemed good to use .Placement.Position.z as both .Start.z and .End.z got the same value. ( Just one place to enter it ...)

Thanks for the advice...
User avatar
adrianinsaval
Veteran
Posts: 5541
Joined: Thu Apr 05, 2018 5:15 pm

Re: Spreadsheet .Start.xyz, .End.xyz

Post by adrianinsaval »

Well you probably can use one to enter the value and an expression to bind the other one to it, or put it in a spreadsheet and bind both to it, or to a custom property in the object itself or in a property container.
User avatar
yorik
Founder
Posts: 13640
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: Spreadsheet .Start.xyz, .End.xyz

Post by yorik »

Placement and Start point indeed affect each other. The placement of a Draft Line/Polyline stays automatically to its start point... Normally indeed you change one, the other changes too. I think when manipulating a Draft line, you should always handle it through the same property (Placement or Start Point), so let the other update without further consequences
Post Reply