I have a large project (hundreds of sheets) and I've changed the text of a keynote for an addendum. Now I must go through and bubble that keynote text in the legends on the sheets where it occurs. Is there a way to find all of these sheets (either with macro or through the UI itself) so that I can be sure that I have found them all?
Solved! Go to Solution.
Solved by cshha. Go to Solution.
This is definitely possible.
The way I would approach this is to:
1. Find all keynotes in the project
FilteredElementCollector tagColl = new FilteredElementCollector(doc).OfClass(typeof(IndependentTag)) .OfCategory(BuiltInCategory.OST_KeynoteTags);
2. Search through those keynotes to find the ones matching the text you want
List<IndependentTag> keynotesMatchingText = (from IndependentTag i in tagColl where (i.get_Parameter(BuiltInParameter.KEYNOTE_TEXT).AsString() == "MyText") select i).ToList();
3. Get the views that own these keynotes
List<ElementId> viewIdsContainingKeynotes = (from keynote in keynotesMatchingText select keynote.OwnerViewId).ToList();
Note that this will only get you the views containing the keynotes, and not the sheets that contain the view.
With the keynotes matching your text and the views that contain them known, you should be able to come up with some way to verify that you haven't missed any.
Revolution Design's Keynote Manager allows you to find all references of a particular keynote.