Skip to content
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

PR: Implementing SitePlacement - method set_SitePlacement not found #820

Open
rayray4105 opened this issue Nov 11, 2024 · 5 comments
Open
Labels
problem Something isn't working

Comments

@rayray4105
Copy link

rayray4105 commented Nov 11, 2024

Problem Description

Hi,

I am trying to implement the option 'Coordinate Base' in our export tool but I am running into a problem. After adding 'SitePlacement' to the exporter config I get the following error on execution. Am I missing a reference?

'Method not found: 'Void BIM.IFC.Export.UI.IFCExportConfiguration.set_SitePlacement(Revit.IFC.Common.Enums.SiteTransformBasis)'.'

Dim selectedConfig As IFCExportConfiguration = IFCExportConfiguration.CreateDefaultConfiguration()
selectedConfig.SitePlacement = Enums.SiteTransformBasis.Project

Using AddOption does not give an error but does not position the model correctly (so it does not work).
Dim ifcOpt As IFCExportOptions = New IFCExportOptions
ifcOpt.AddOption("SitePlacement", "2")

Using the UI we can set the Coordinate Base and export how it is supposed to be.

regards,
Raymond

Revit Version

2024.0.x

IFC for Revit Addon Version

24.x.x

Windows Version

11 22H2

@rayray4105 rayray4105 added the problem Something isn't working label Nov 11, 2024
@PeterTranberg
Copy link

Our developers has a similar problem in 2023, 2024 and 2025

@andydandy74
Copy link

Should work via a JSON file - see #761

@rayray4105
Copy link
Author

we have already tried but as mentioned in the ticket that does not work. The code runs fine but the model is not coordinated correctly (default location is used).

Dim ifcOpt As IFCExportOptions = New IFCExportOptions
Dim selectedConfig As IFCExportConfiguration = IFCExportConfiguration.CreateDefaultConfiguration()
ifcOpt.AddOption("SitePlacement", 2)
selectedConfig.UpdateOptions(ifcOpt, activeViewId)

@rayray4105
Copy link
Author

For now we have seemed to be able to resolve this issue by adding Nuget package: Revit_All_Main_Versions_IFC_x64

https://www.nuget.org/packages/Revit_All_Main_Versions_IFC_x64/2024.0.0?_src=template

Make sure you use the correct version.

@parrela
Copy link

parrela commented Nov 21, 2024

[REVIT-229874]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
problem Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants