From 1ee0a5ce4d949ed0b996d0ca4ae5dbfc3d7a5288 Mon Sep 17 00:00:00 2001 From: kike-garbo Date: Mon, 5 Aug 2024 19:41:55 +0200 Subject: [PATCH] `TaskDialog` only allows 4 command buttons. --- src/RhinoInside.Revit.Loader/Loader.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/RhinoInside.Revit.Loader/Loader.cs b/src/RhinoInside.Revit.Loader/Loader.cs index 9a00dac56..864390746 100644 --- a/src/RhinoInside.Revit.Loader/Loader.cs +++ b/src/RhinoInside.Revit.Loader/Loader.cs @@ -113,7 +113,7 @@ static Distribution PickDistribution() } ) { - for (int d = 0; d < 4 && d < available.Length; d++) + for (int d = 0; d < 4 && d < Math.Min(available.Length, 4); d++) { var distribution = available[d]; taskDialog.AddCommandLink