Good Day,
I am trying to obtain information below through from Rhino to python in Grasshopper. Anyone can shed me some light in terms of programming.
- Rhino Version
- Rhino File Size
Good Day,
I am trying to obtain information below through from Rhino to python in Grasshopper. Anyone can shed me some light in terms of programming.
For number 2;
import os
filePath3dm = Rhino.RhinoDoc.ActiveDoc.Path
print os.path.getsize(filePath3dm)
Hi @jia.yeap,
I didn’t understand you.
The version method is not working for some reason, at least in Rhino 6.
The file path is working but returns the size in bytes:
import Rhino
import os
print Rhino.RhinoDoc.ActiveDoc.ReadFileVersion()
filePath3dm = Rhino.RhinoDoc.ActiveDoc.Path
print os.path.getsize(filePath3dm) / (1024**2) # in MB