不能通过API来创建Project Parameter

本文解答了如何在Revit项目文档中使用API创建项目参数的问题。由于直接创建不可行,文章提供了在族文档中创建的方法,即通过FamilyManager.AddParameter()方法实现。

 

问:

如何使用API在项目中添加项目参数?Revit操作界面如下:

 

在SDK中一个例子CreateShared 介绍了如何创建共享参数,不知道如何创建项目参数(Project Parameter)?

 

 

答:

在项目文档(Project document)中,我们无法用API来创建Project Parameter。 用API只能创建共享参数。

如果是在族文档(Family document)中,可以用API创建Project Parameter的。方法是通过FamilyManager.AddParameter()  方法。

 AddParameter(String, BuiltInParameterGroup, Category, Boolean) Add a new family type parameter to control the type of a nested family within another family.
 AddParameter(String, BuiltInParameterGroup, ParameterType, Boolean) Add a new family parameter with a given name.

 

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值