ifcGUID of Windows

Heey guys , i hope you are doing good y’all!
I have a concern , I am extracting some properties of windows and i need their IDs to link each parameter value with its corresponding element .
Yet , when i use the IfcGUID to have their IDs , i get this:

Also i am in the need of IfcGUID not the the ID that starts with “#…”

I hope someone can help , Thank youu !
Regards

1 Like

@saqouanealaa

…it looks like that you run your script severial times, before you extracted familiy location point. Open/close your script, it should run well. If not follow my instraction:

you need to backwrite the IfcGUID back to the window.

1.) export Ifc write IfcGUID back
2.) extract GUID

import clr

clr.AddReference('RevitAPI')
from Autodesk.Revit.DB import *
from Autodesk.Revit.DB.Structure import *

clr.AddReference('RevitAPIUI')
from Autodesk.Revit.UI import *

clr.AddReference('System')
from System.Collections.Generic import List

clr.AddReference('RevitNodes')
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
clr.ImportExtensions(Revit.Elements)

clr.AddReference('RevitServices')
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

doc = DocumentManager.Instance.CurrentDBDocument
uidoc=DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument

windows = FilteredElementCollector(doc).OfCategory(BuiltInCategory.OST_Windows).WhereElementIsNotElementType().ToElements()

GUIDs = [ i.get_Parameter(BuiltInParameter.IFC_GUID).AsValueString() for i in windows]

OUT = windows, GUIDs

1 Like

Thank you !

1 Like