
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I have this code.
ParameterValueProvider pvp = new ParameterValueProvider(new ElementId(5539));
FilterStringRuleEvaluator fsre = new FilterStringEquals();
FilterRule fRule = new SharedParameterApplicableRule("sharedparameter");
ElementParameterFilter filter = new ElementParameterFilter(fRule);
FilterRule fRule2 = new FilterStringRule(pvp, fsre,"",false);
ElementParameterFilter filter2 = new ElementParameterFilter(fRule2);
FilteredElementCollector col = new FilteredElementCollector(doc).WhereElementIsNotElementType().WherePasses(filter).WherePasses(filter2);
This code selects all elements in the project that have the specified shared parameter and where the value is "". But I'm looking for the inverse of this. Getting all elements that have the shared parameter and has some value. Is there some way to inverse the FilterStringRule?
Solved! Go to Solution.