updated to Revit 2023 SDK

This commit is contained in:
Jeremy Tammik
2022-04-07 09:12:58 +02:00
parent e3434c5200
commit ab02648986
342 changed files with 6496 additions and 3140 deletions
@@ -113,7 +113,7 @@ namespace Revit.SDK.Samples.DoorSwing.CS
IEnumerable<ViewPlan> viewPlans = from elem in
new FilteredElementCollector(door.Document).OfClass(typeof(ViewPlan)).ToElements()
let viewPlan = elem as ViewPlan
where viewPlan != null && !viewPlan.IsTemplate && viewPlan.GenLevel.Id.IntegerValue == door.LevelId.IntegerValue
where viewPlan != null && !viewPlan.IsTemplate && viewPlan.GenLevel.Id == door.LevelId
select viewPlan;
if (viewPlans.Count() > 0)
{
@@ -187,7 +187,7 @@ namespace Revit.SDK.Samples.DoorSwing.CS
foreach (Category category in categories)
{
if (category.Id.IntegerValue.Equals((int)boundCategory))
if (category.BuiltInCategory == boundCategory)
{
return true;
}
+2 -6
View File
@@ -22,7 +22,6 @@
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<CodeAnalysisRuleSet />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
@@ -32,7 +31,6 @@
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<CodeAnalysisRuleSet />
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
<DebugSymbols>true</DebugSymbols>
@@ -41,8 +39,7 @@
<DebugType>full</DebugType>
<PlatformTarget>x64</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>
</CodeAnalysisRuleSet>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
<OutputPath>bin\x64\Release\</OutputPath>
@@ -52,8 +49,7 @@
<DebugType>pdbonly</DebugType>
<PlatformTarget>x64</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>
</CodeAnalysisRuleSet>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup>
<RunPostBuildEvent>OnOutputUpdated</RunPostBuildEvent>
+1 -1
View File
@@ -427,7 +427,7 @@ namespace Revit.SDK.Samples.DoorSwing.CS
else if ((null != door.Room) && (null != door.FromRoom))
{
// door.Room are consistent with door.FromRoom, so need update.
if (door.Room.Id.IntegerValue.Equals(door.FromRoom.Id.IntegerValue))
if (door.Room.Id == door.FromRoom.Id)
{
if (updateGeo) // update geometry
{