Message 1 of 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
the code:
try
{
ifcExport(doc, v, "name_of_file", "C:\\test123\\ifc_out");
}
catch (Exception ex) { File.AppendAllLines(path, new string[] { "ifcExport Exception: " + ex.Message }); }
public void ifcExport(Document doc, Autodesk.Revit.DB.View viewExport, string filename, string path)
{
IFCExportOptions ifcOptions = new IFCExportOptions();
ifcOptions.ExportBaseQuantities = true;
ifcOptions.FamilyMappingFile = "C:\\test123\\SAS_IFC-export.txt";
ifcOptions.FileVersion = IFCVersion.IFC2x3;
ifcOptions.FilterViewId = viewExport.Id;
ifcOptions.WallAndColumnSplitting = true;
doc.Export(path, filename, ifcOptions);
}
but for some reason it keeps giving me this error message, no matter what folder i choose to export to.
Access to the path 'C:\test123\ifc_out' is denied.
and to make the case even stranger, if i make an nwc export to the exact same folder and that works without any errors or warnings.
I have no idea why it does give me this error for an ifc file while i can write other file types to the folder without any issues.
Edit:
it made me also wonder, when i installed the IFC for revit (from Autodesk) do i even need to call the default doc.export ? or is there another method i should be calling to make the ifc exports ?
Solved! Go to Solution.