I have a family with 50 different instance Parameters of type Number/Integer. Each realization of this family has only few of those parameters with values different than zero. I created a Label which shows the values of those parameters. When almost all of them have value equal to zero, I end up with an enormous Label with no senseful Information. If the Parameter type is set to "Text", the Label only shows those parameters that aren't blank. I cannot sort them later in schedules though. Is there a way to hide the Parameters with values equal to zero?
A similar question was already asked here: https://forums.autodesk.com/t5/revit-mep-forum/do-not-show-zero-value-in-tag/td-p/5767400 but the answer does not satisfy my needs as I have a lot of Parameters and Controlling each and evey one of them like that is out of the question
Set up a yes/no visibility parameter for each, driven by an IF/THEN statement
I have the same concern as drzamich. A label (in a tag) of text parameters behaves well if there is no info in the text parameters, i.e., the text parameters are not displayed, so a label of ten rows of text parameters shows only the parameters that are populated in the instance of the tagged family. However, when an integer or number parameter is in the label, it shows no matter what its value and any attached suffix shows with it. This visibility doesn't behave logically, either. The Break operator doesn't see the zero value, so the rows containing zero values are concatenated.
The attached graphic shows the behaviour. Each row represents "SYSTEM:" QTY (a number) X (suffix) "CONNECTOR TYPE;" A SECOND QTY OF A SECOND CONNECTOR TYPE; TO A DESTINATION (BREAK). Because the second connector isn't required here, its quantity is zero and shouldn't show. Because there are only three systems of a possible ten needed here, the last fourteen quantities shouldn't show. You can see that the last Break after "RS" didn't feed the next line because there's no text in the next line, but the zeroes and the "X" suffixes appear anyway.
Is there a way to convert a number to text for the purpose of populating the label, while feeding the number itself to the schedules?
@Anonymous
Apologies for the late reply. If you have already sorted this out, perhaps the following will help future readers of this thread.
So far as I know, the formula feature in Revit does not have any functions that will convert integers to strings. You could set up a parallel set of text parameters, one for each integer parameter, and use Dynamo to take the integer parameter values, convert them to strings, and then push the strings onto the text parameters. That will not automatically update every time you change one of the integer values; you will need to remember to re-run the Dynamo graph to update the text parameters.
In a test case, I set up three instance-based integer parameters that apply to Specialty Equipment families (Int01, Int02 and Int03). Three additional text parameters (Str01, Str02 and Str03) were also applied to Specialty Equipment families. The Dynamo graph shown in the image below selects all of the Specialty Equipment in the current project, gets the integer parameter values, converts them to strings and then sets the corresponding text parameter to the converted string value.
The attached ZIP file has a sample Revit project and family files (2018 format), the shared parameters file used to define the parameters and a Dynamo file from which the image above was created (Dynamo 1.3).
Hi
We are at 2022 and still can't "reset" a parameter value to null. But here is a workaround using a formula in a tag. This applies to shared parameters and requires a second "buddy" parameter to be created. Lets say your main parameter is called "MyParameter_Area", create a second one called "MyParameter_Area_Null" of the same unit type.
Now, in the tag editor change the line that would normally display the value of "MyParameter_Area" and change it to a calculated field:
if(MyParameter_Area > 0 m², MyParameter_Area, MyParameter_Area_Null)
Now when "MyParameter_Area" is 0 (or even null) then the value of "MyParameter_Area_Null" is displayed which of course should be null as it shouldn't ever be set to anything else. This of course means the tag line is removed from the tag on screen. I moved the "MyParameter_Area_Null" parameter to the Visibility group to keep it visibly separate from the other one to prevent inadvertent inputs to help keep the value at null. I guess the same technique could be used on schedules.
I just saw this. Very cool. I will play with it.
I have worked around by making a .csv table with text in the 0th column and numbers in the 1st column. The numerical value is fed to the size_lookup function that returns the text value which then populates label. The .csv has thousands of numbers, but seems speedy enough. I can get decimal values by appropriate pre-and post multiplication and concatenation in the label.
Good stuff. Got me out of a hole. I found that you don't even need to bring the "null" parameter into the Project. As long as you add it into your Label family that appears to be enough. So the end user will never actually see the "null" parameter so won't be able to inadvertently add a value thus rendering its "null" value useless.
In my case I tested on a Multi-Category Tag which works fine. I discovered that this technique doesn't work on a tag of type "Area Tag". These tags seem to display the unwanted tag lines whether the value behind the parameter is "null" or not even without using the formula. So "Area Tags" behave different to other tags in that respect.
Of course, what we all really want is a way of setting a shared parameter value back to null either via the API or the UI.
Do this - cremate a “compound” label. Add ALL the parameters to the same label. Click the Break checkbox between each. When the label is placed, click twice (as opposed to double clicking) to bring up a dialog box. Fill in the parameter values as needed. Parameters with a blank Values field will not show up in the view.
Can't find what you're looking for? Ask the community or share your knowledge.