简体   繁体   English

Revit API:自定义ModelLine

[英]Revit API: Custom ModelLine

We're developing a plugin for revit to determine sections of a construction plan. 我们正在开发用于revit的插件,以确定施工计划的各个部分。

Therefore we need something like model lines, but they need to be bound to a certain level. 因此,我们需要像模型线这样的东西,但是需要将它们绑定到特定级别。 We also need to add custom Properties to these elements. 我们还需要向这些元素添加自定义属性。

What should I use? 我应该使用什么? Are model lines ok? 模型线可以吗? How can properties be added to them? 如何将属性添加到它们? How can they be bound to a certain level? 如何将它们绑定到某个级别?

If the data you need to store is simple enough to store as family parameters, you could create a generic line based family. 如果您需要存储的数据足够简单,可以作为族参数存储,则可以创建基于通用行的族。 The family would contain a model line and parameters to store the required data. 该族将包含一条模型线和用于存储所需数据的参数。 Your addin can then calculate the required sketchplanes and place the family as you would the standard model lines. 然后,您的插件可以计算所需的草图平面,并像标准模型线一样放置族。 The user will then have easy access to the associated data through the built-in properties window even when you addin is not installed. 这样,即使未安装插件,用户也可以通过内置的属性窗口轻松访问关联的数据。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM