Skip to content

BlenderBIMSpreadsheet.py changes for Bonsai #10

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions BlenderBIMSpreadsheet/BlenderBIMSpreadsheet.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
from bpy_extras.io_utils import ImportHelper
from bpy.types import (Operator, PropertyGroup)

import blenderbim.bim.import_ifc
from blenderbim.bim.ifc import IfcStore
import blenderbim.tool as tool
import bonsai.bim.import_ifc
from bonsai.bim.ifc import IfcStore
import bonsai.tool as tool
import ifcopenshell

import openpyxl
Expand Down Expand Up @@ -497,7 +497,7 @@ def execute(self, context):
worksheet.write_formula(str(column_letter)+'1', total_volume)

# Close the Pandas Excel writer and output the Excel file.
writer.save()
writer._save()
open_file(blenderbim_spreadsheet_properties.my_xlsx_file)

print (time.perf_counter() - start_time, "seconds for the .xlsx to be written")
Expand Down Expand Up @@ -530,7 +530,7 @@ def execute(self, context):
construct_data_frame.df.to_excel(writer_ods, sheet_name=blenderbim_spreadsheet_properties.my_workbook, startrow=0, header=True, index=False)

worksheet_ods = writer_ods.sheets[blenderbim_spreadsheet_properties.my_workbook]
writer_ods.save()
writer_ods._save()

open_file(blenderbim_spreadsheet_properties.my_ods_file)
blenderbim_spreadsheet_properties.my_file_path = IfcStore.path.replace('.ifc','_blenderbim.ods')
Expand Down Expand Up @@ -822,4 +822,4 @@ def unregister():
bpy.utils.unregister_class(BlenderBIMSpreadSheetPanel)

if __name__ == "__main__":
register()
register()