Error Getting Grid Reference in Revit API
After Revit 2018, the method for obtaining Grid Reference has been modified. You need to use the following code to retrieve it:
1 | foreach (Grid grid in grids) |
Previously, you needed to get the Grid’s Curve.Reference to create dimensions:
1 | gridReferences.Append(grid.Curve.Reference); |
The change should be made to obtain Grid References more safely and conveniently. For details on the official response regarding this matter, please refer to the article below:
Invalid Number of References

All articles on this blog are licensed under CC BY-NC-SA 4.0 unless otherwise stated.





