DesignAutomationHandler is a Revit addin that allows users to run and debug their Design Automation for Revit application locally using desktop Revit.
- Forge Account: Learn how to create a Forge Account, activate your subscription, and create an app at this tutorial.
- Visual Studio: 2019 or newer
- .NET Framework basic knowledge with C#
- Revit 2019: required for compiling plugin changes
- Build the solution
DesignAutomationHandler
, compiling DesignAutomationHandler for Revit 2018 (DesignAutomationHandler2018
), Revit 2019 (DesignAutomationHandler2019
), Revit 2020 (DesignAutomationHandler2020
), Revit 2021 (DesignAutomationHandler2021
), Revit 2022 (DesignAutomationHandler2022
), Revit 2023 (DesignAutomationHandler2023
), and Revit 2024 (DesignAutomationHandler2024
)
Design Automation for Revit currently supports Revit 2018, 2019, 2020, 2021, 2022, 2023, and 2024.
-
Copy/paste the
DesignAutomationHandler.addin
into the "Addins" folderC:\ProgramData\Autodesk\Revit\Addins\XXXX\
, whereXXXX
is the Revit version (e.g. 2018, 2019, 2020, 2021, 2022, 2023, 2024) you intend to run. -
Copy/paste the
.addin
file of your Design Automation for Revit plugin into the same folderC:\ProgramData\Autodesk\Revit\Addins\XXXX\
.
DesignAutomationHandler doesn't support local testing/debugging of more than one addin at a time.
Revit needs the
DesignAutomationBridge.dll
to be in the same folder as your addin's dlls.
Starting Revit:
- If your addin requires an input Revit model at startup, then open the file in Revit before running the addin or specify the file using a startup argument.
If you have json parameter defined to run the
WorkItem
in Design Automation, you can save the json payload as a json file in the same folder as your input Revit file.
For example: if
CountItParams
is the name of the parameter defined in the your Design AutomationActivity
, then you should create a fileCountItParams.json
with contents{"walls": false,"floors": true,"doors": true,"windows": true}
and save it to the folder which contains your input Revit model.
-
In the Revit ribbon, navigate to the
Add-Ins
tab, then clickExternal Tools
, and click theDesignAutomationHandler
command. Your addin will by executed! A dialog will pop-up to report the execution result. If the execution was successful, the dialog will indicate where you can find the output(s). They go to the folder which contained your input files. -
If your plugin doesn't require any input files, start Revit and run the
DesignAutomationHandler
command without any additional setup. If you have json parameter defined to run theWorkItem
in Design Automation, a dialog will instruct you where to put your json file.
You can rerun the same addin without restarting Revit.
To run different addin, repeat the setup steps above.
Currently, the DesignAutomationHandler doesn't support multiple input files. (This feature is supported by Design Automation on Forge.)
Documentation:
Desktop APIs:
Blog articles:
Please see the LICENSE file for full details.
Lijuan Zhu and Ashwin Shivashankar