Message 1 of 1
The curious problem of shared parameters
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
SharedParameterElement are here to stay if you are user.
Every time we add SharedParameter to project(or family) it will be on list of SharedParameterElement, you can try to purge it, delete every element, and yet this secret list will stay with all your past.
The only way is to delete it with api, for example:
FilteredElementCollector fec = new FilteredElementCollector(doc).OfClass(typeof(SharedParameterElement ));
var spList = fec.ToList();
using (Transaction trans = new Transaction(doc, "sp")) {
trans.Start();
for (int i = 0; i < spList.Count; i++) {
var element = spList[i];
doc.Delete(element.Id);
}
trans.Commit();
}
so If you made mistake in making a parameters, changing LENGTH to a NUMBER(in file), can open a can of worms.
Well it is time to make a new guid for 60 parameters, and then replace them in 120 families.
Have a nice weekend!
-------------------------------------------------------------
--------------------------------|\/\/|------------------------
do not worry it only gonna take Autodesk 5 years to fix bug
--------------------------------|\/\/|------------------------
do not worry it only gonna take Autodesk 5 years to fix bug