I’m having a bit of trouble on where to start. I’m a bit new to Dynamo. I’m looking for a way to search all my text notes in my project against a list of abbreviations and have it report to me if its in the project or not. It can report true and false that its in the Revit file and that it is not. The picture is what I have so far. But I’m not that experienced. Right now I got to look up one abbreviation CONC but I end up getting CONCRETE as well and I’m not sure how to stop that from occurring. There is about 100 abbreviations I have to look up. Any help would be appreciated.
Search for “ CONC ”
(including the space before and after the phrase) and “CONC. ”
to catch cases where a period was used at the end of the abbreviation.
How would i be able to do it with multiple abbreviations? TYP, CONC, TOF, Etc… Would I have to make a giant code block ? I have about 100 of these lol. Also our firm does not add a period at the end of the abbreviation, but the space worked fine.
If you’ve got a list of them somewhere (e.g. Excel sheet) you could import that instead of typing them out.
If there was any pattern to the abbreviations that differed from normal text you could do some regex to find them but if you’ve just got “250mm CONC WALL”, how do you tell a computer that “CONC” is an abbreviation but “WALL” isn’t without explicitly entering “CONC”.
Oh yeah that’s true. My firm is a bit weird when it comes to their standards and its very hard to change a old mans mind lol. I’ll keep this in the back of my mind.
I cant figure out what im doing wrong. Other than maybe being a different version. Im using revit 2024.
String.Contains
will work for multiple abbreviations, you’ll just need to use list levels and manage the list structure. Check each note for the list of abbreviations then filter the notes based on the abbreviation check. That will give you all notes that contain a given term, group by term.
Hi I also tried it in 2024 and same as you I’m getting an empty value, I don’t whats with the OOTB node but I tried getting directly via API and I got the result
graph is attached
StrToMatch.dyn (10.0 KB)
That’s because string.strip()
only removes the leading and trailing white space. It would only give you a match if your term was the only term in the string. That’s why you need to provide your term with spaces on either end (to account for the term within a sentence) or with a period at the end (to account for the term at the end of a sentence) - allowing you to search the whole note at once.
Sweet Thank you for your response. I’ve been at this for 4 hours lol I got it to kind of work but now I’m having issues when I import my excel sheet. So as you said, I’ve been trying to figure out how to add a space before and after the acronym, but I cant figure it out. I’ll upload the excel file, graph, a and sample project. My next step is to only check the views that are on sheets. And then to report back which abbreviations are on the project and export that list to a excel sheet. If you can help me and stear me in the right direction that would be great. Also how did you learn dynamo. Are there any good resources out there. Thank you again.
Abbreviations.xlsx (14.2 KB)
abbr 1.dyn (42.2 KB)
Project1.rvt (7.2 MB)
Abbreviations.xlsx (14.2 KB)
I think i am making some progress. I gotta clock out but ill let you know how it goes tomorrow.
I figured it out!!! but its a bit shameful lol. I ended up using ChatGPT to write a script to exactly what I wanted.
Abbreviation Check - You need to link a excel file as the in put. This will be your companies standard list. It will check text notes, symbols, and dimensions. Then for the output you need to link into another excel file and it will only list the words that matched.
Abbreviation Import - It import the list that was created. You will have to make a key schedule and connect the parameters.
Abbreviations Import.dyn (102.8 KB)
Abbreviation Check.dyn (315.4 KB)