Doubt in the Spreadsheet module

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!
satheesh
Posts: 35
Joined: Tue May 10, 2016 12:43 pm

Doubt in the Spreadsheet module

Post by satheesh »

Hi guys,

In the spreadsheet module, how to create a single spreadsheet for different parts..?? Is there any way to do that?

Thanks & Regards

satheesh

OS: Windows 7
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6703 (Git)
Build type: None
Branch: releases/FreeCAD-0-16
Hash: 2ce5c8d2e3020d05005ed71f710e09e9aa561f40
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
User avatar
DeepSOIC
Veteran
Posts: 7896
Joined: Fri Aug 29, 2014 12:45 am
Location: used to be Saint-Petersburg, Russia

Re: Doubt in the Spreadsheet module

Post by DeepSOIC »

HI!
If you make all the parts in question in one document (aka project), there is nothing special you need to do. Just put them all in one spreadsheet :P
If you want cross-document links - there is some support for that. See Expressions wiki page.
satheesh
Posts: 35
Joined: Tue May 10, 2016 12:43 pm

Re: Doubt in the Spreadsheet module

Post by satheesh »

Thank you so much.... That helps me lot.. :D :D
satheesh
Posts: 35
Joined: Tue May 10, 2016 12:43 pm

Re: Doubt in the Spreadsheet module

Post by satheesh »

Hi guys,

Is there any option to give round off function in the Spreadsheet module...?


Thanks & Regards
satheesh
User avatar
NormandC
Veteran
Posts: 18589
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Doubt in the Spreadsheet module

Post by NormandC »

From the Sketcher Workbench wiki page:
The wiki wrote:The additional functions: ceil, floor, trunc, and round are available in FreeCAD
I just tried in a cell:

Code: Select all

round(12.5463)
And it returns 13.

Now the question is, can it be rounded to a specific decimal point...
satheesh
Posts: 35
Joined: Tue May 10, 2016 12:43 pm

Re: Doubt in the Spreadsheet module

Post by satheesh »

Thank you NormandC :D
eivindkvedalen
Posts: 602
Joined: Tue Jan 29, 2013 10:35 pm

Re: Doubt in the Spreadsheet module

Post by eivindkvedalen »

NormandC wrote: I just tried in a cell:

Code: Select all

round(12.5463)
And it returns 13.

Now the question is, can it be rounded to a specific decimal point...
Something like round(A1 * 100) / 100 will round to two decimals.

Eivind
mario52
Veteran
Posts: 4696
Joined: Wed May 16, 2012 2:13 pm

Re: Doubt in the Spreadsheet module

Post by mario52 »

hi
NormandC wrote:Now the question is, can it be rounded to a specific decimal point...

Code: Select all

>>> from math import *
>>> a = 12.124896542
>>> round(a)
12.0
>>> round(a,4) # 4 decimals
12.1249
>>> floor(a) # inferior
12.0
>>> ceil(a) # superior
13.0
>>> 
Maybe you need a special feature, go into Macros_recipes and Code_snippets, Topological_data_scripting.
My macros on Gist.github here complete macros Wiki and forum.
satheesh
Posts: 35
Joined: Tue May 10, 2016 12:43 pm

Re: Doubt in the Spreadsheet module

Post by satheesh »

whether all the python functions will work in the spreadsheet module??
eivindkvedalen
Posts: 602
Joined: Tue Jan 29, 2013 10:35 pm

Re: Doubt in the Spreadsheet module

Post by eivindkvedalen »

satheesh wrote:whether all the python functions will work in the spreadsheet module??
No, just the functions in the documentation. The spreadsheet does not embed python code, as that would be a security issue.

Eivind
Post Reply