Filled Region Warning Message: Parameters storage type is not a string

Hi there:

I’m trying to get a filled region area into a schedule. It looks like it’s working but with a warning message that says: “Parameters storage type is not a string”. I tried changing the strings per code blocks but it still saying the same. Any idea of how to get rid of that message?

Also, I would like to filter the search using another parameter. For example: I have a parameter for comments. I’m sorting in the schedule if every filled region comment is equal to “LEED”.

It looks like the script is reading +12,000 filled regions and it delays the processing a little.

Can somebody help me to achieve this? I am new to Dynamo. I found it’s so useful to get information that I can’t with Revit. But really I don’t know how Dynamo works pretty well. Thanks in advance for all you inputs.

1 Like

@airizarry

hi,

Nice Task, i did this way, so there is no need to convert to string…

KR

Andreas

Thank you. I did it exactly like you have it in your screenshot but it still appearing the same warning message.

@airizarry

can you share a screenshot, like i did with the dropdown menus and the warning?

KR

Andreas

Think filledregion already have a buildin parameter there gives area and will Update without run Dynamo…just info😀

yes indeed! but you can not schedule it! i had this topics with “Carpets”. I listed it separeted in a .xls sheet @sovitek

2 Likes

ahh i see :wink:

@airizarry

Can you check if it is realy all area.Values?

This is all very short and fast in just Python:
The AsDouble() makes sure the Area is returned as a number and slots into the Filled Region Area defined as a area (double).
You could further filter the regions for just the ones you want with one or two more lines of code.
Run it through pyRevit as a script.py and it is even faster without the overhead of Dynamo.

import Autodesk
from Autodesk.Revit.DB import *
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc = DocumentManager.Instance.CurrentDBDocument
mySelected = FilteredElementCollector(doc).OfClass(FilledRegion).WhereElementIsNotElementType().ToElements()
TransactionManager.Instance.EnsureInTransaction(doc)

for e in mySelected:
    myAreaValue = e.get_Parameter(BuiltInParameter.HOST_AREA_COMPUTED).AsDouble()
    myFilledRegionArea = e.LookupParameter(“Filled Region Area”)
    newAreaParam = myFilledRegionArea.Set(myAreaValue)

TransactionManager.Instance.TransactionTaskDone()

myResult = mySelected

OUT = myResult
import Autodesk
from Autodesk.Revit.DB import *
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc = DocumentManager.Instance.CurrentDBDocument
mySelected = FilteredElementCollector(doc).OfClass(FilledRegion).WhereElementIsNotElementType().ToElements()
TransactionManager.Instance.EnsureInTransaction(doc)

for e in mySelected:
    myAreaValue = e.get_Parameter(BuiltInParameter.HOST_AREA_COMPUTED).AsDouble()
    myFilledRegionArea = e.LookupParameter(“Filled Region Area”)
    newAreaParam = myFilledRegionArea.Set(myAreaValue)

TransactionManager.Instance.TransactionTaskDone()

myResult = mySelected

OUT = myResult

@aaronrumple