Select to view content in your preferred language

Model Builder Calculate Field on many fields with user input?

01-26-2024 01:49 PM
New Contributor III

Hi all,

I am trying figure out the best way to add parameters to have values filled in based on an excel sheet. I am not sure if I should just somehow import the excel file and have it fill in the values it self (never done that). Or if I should have about 17~ Calculate Fields with Parameters set so users can input the value from that excel sheet. I found that idea a bit ridiculous which made me want to inquire within the community.

The Model builder takes CAD Files and turns them into multipatch features (currently). I want the users to be able to input the values in the fields before I load the data into my SDE Multipatch Feature and my AGOL Hosted Feature Layer. That way there is minimal going back and forth, its all done in one context menu versus running this process, then running a Task to input the values.



I've also attached the same images below, but basically the very last step is where I would create all those calculate fields and set the expression as a parameter and have the user input the value.

After I've figured out the step above and append the data to my AGOL Hosted Feature Layer and Database Layer, The very final step would be to truncate "PolygonTo3D_First" and "To_Multipatch" as well as delete the Feature Dataset created in the CAD to Geodatabase Geoprocessing tool. 


All help would be appreciated, this is my first time using Model Builder so I am not really sure how to work with user inputs over several fields.

Kinds regards,



0 Kudos
2 Replies
MVP Regular Contributor

Not sure I understand the workflow or the question. There's a lot of stuff mentioned in this post.

Processing CAD or Excel data requires consistent inputs.

What are you grabbing  from the Excel? It's possible to pass values from an input Excel as parameters to geoprocessing tools. But what row/value? Will this change? Are the users uploading it? Will they consistently format the excel?

Parameters can be entered when users open the model as a geoprocessing tool. You can have them be specified to one tool within the model, or reuse them across multiple tools, to help avoid re-entry.

You can't really have a parameter entered halfway through a model. ArcGIS Tasks could help with this - it can string together steps, instructions, geoprocessing tools... to combine two models and allowing the output and later user entry for the second model run.

0 Kudos
New Contributor III

This is what the excel sheet looks like:


Note the second column has "Height (Metres)". the value will always be located in B2. This is a standardized excel sheet. There will be no change as these are the very specific metrics my planning department cares about. If it does change, then I simply have to update the model, but they're aware that a change is not so simple. Additionally, the CAD files are also standardized where the standardization states that they must create a layer named "Building_Footprint" in the shape of the building footprint. They also must use an LWPolyline Entity and connect the End of the line to the Start, which then allows ArcGIS Pro to recognize it as a Polygon. That's how I've made sure there are consistent inputs. 

In regards to a parameter half way, the user would state the height in the Calculate Field > Expression Parameter previous to starting the geoprocessing tool. It isn't reliant on a pause for the user, this will all be done prior to hitting Run. I have the model working this way, but I would like to use the excel sheet in its place. So instead the user will have an input for the CAD file, then an input for an Excel file in the geoprocessing tool, and that should suffice.

0 Kudos