Skip to content

Update Nice3point.Revit.Extensions - #84

Merged
Nice3point merged 1 commit into
developfrom
renovate/nice3point.revit.extensions
Aug 10, 2026
Merged

Update Nice3point.Revit.Extensions#84
Nice3point merged 1 commit into
developfrom
renovate/nice3point.revit.extensions

Conversation

@Nice3point

Copy link
Copy Markdown
Owner

This PR contains the following updates:

Package Type Update Change
Nice3point.Revit.Extensions nuget patch 2021.5.32021.5.4
Nice3point.Revit.Extensions nuget patch 2022.5.32022.5.4
Nice3point.Revit.Extensions nuget patch 2023.5.32023.5.4
Nice3point.Revit.Extensions nuget patch 2024.3.32024.3.4
Nice3point.Revit.Extensions nuget patch 2025.2.32025.2.4
Nice3point.Revit.Extensions nuget patch 2026.1.32026.1.4
Nice3point.Revit.Extensions nuget patch 2027.0.32027.0.4

Release Notes

Nice3point/RevitExtensions (Nice3point.Revit.Extensions)

v2027.0.4

Compare Source

Extensible storage units

A schema field of type double, float, XYZ, or UV declares a spec, and every read and write of such a field names the unit the value is expressed in.
SaveEntity and LoadEntity passed no unit.
They served string, integer, boolean, ElementId, and Guid fields, and threw on everything measured.

Storing a wall thickness used to drop out of the extensions:

var field = schema.GetField("Thickness");
var entity = wall.GetEntity(schema);
entity.Set(field, 0.5, UnitTypeId.Meters);
wall.SetEntity(entity);

Now the unit travels with the value:

wall.SaveEntity(schema, 0.5, "Thickness", UnitTypeId.Meters);
wall.SaveEntity(schema, 0.5, "Thickness", DisplayUnitType.DUT_METERS); // Revit 2020 and lower

var thickness = wall.LoadEntity<double>(schema, "Thickness", UnitTypeId.Meters);
  • element.SaveEntity(schema, data, fieldName, unitTypeId)
  • element.LoadEntity<T>(schema, fieldName, unitTypeId)

The unit must be compatible with the spec the field was built with, otherwise Revit rejects the call.

LoadEntity also stops allocating an entity for an element that holds no data, and returns the default value directly.

Agents can now use this directly using a skill: https://github.com/Nice3point/revit-skills

Identifier values

Revit 2024 widened ElementId from 32 to 64 bits.
Value replaced IntegerValue, the constructor started taking an Int64, and the underlying type of the BuiltInCategory and BuiltInParameter enumerations grew with it.
A constant now converts into an identifier without losing anything.

A cast carries the same split.
(int)category compiles on either side of that boundary and names a different type on each, and an assembly built against the older API meets cast exceptions on the newer one.

Reading the number behind an ElementId used to take a conditional:

#if REVIT2024_OR_GREATER
    var value = elementId.Value;

#else
    var value = elementId.IntegerValue;

#endif

Now it is one call, and the value converts back:

var value = elementId.ToLong();
var elementId = value.ToElementId();

BuiltInCategory and BuiltInParameter uses the same convention:

var categoryValue = BuiltInCategory.OST_Walls.ToLong();
var parameterValue = BuiltInParameter.WALL_TOP_OFFSET.ToLong();
  • elementId.ToLong()
  • builtInCategory.ToLong()
  • builtInParameter.ToLong()
  • value.ToElementId()

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot.

Copilot AI lite review requested due to automatic review settings August 10, 2026 01:53
@Nice3point Nice3point added the maintenance ⚙️ Some regular maintenance updates label Aug 10, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the centrally-managed NuGet package versions for Nice3point.Revit.Extensions across supported Revit year conditions in Directory.Packages.props, keeping this toolkit aligned with the latest patch releases of the extensions library.

Changes:

  • Bumped Nice3point.Revit.Extensions from 2021.5.32021.5.4
  • Bumped Nice3point.Revit.Extensions from 2022.5.32022.5.4
  • Bumped Nice3point.Revit.Extensions from 2023.5.32023.5.4
  • Bumped Nice3point.Revit.Extensions from 2024.3.32024.3.4
  • Bumped Nice3point.Revit.Extensions from 2025.2.32025.2.4
  • Bumped Nice3point.Revit.Extensions from 2026.1.32026.1.4
  • Bumped Nice3point.Revit.Extensions from 2027.0.32027.0.4

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@Nice3point
Nice3point merged commit 82a6de7 into develop Aug 10, 2026
2 checks passed
@Nice3point
Nice3point deleted the renovate/nice3point.revit.extensions branch August 10, 2026 06:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance ⚙️ Some regular maintenance updates

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants