How to develop and run .NET plugins in BricsCAD V26?
Starting with BricsCAD V26, the managed runtime has been upgraded to .NET 8 (formerly .NET Core).
This replaces the legacy .NET Framework 4.8 runtime used in previous versions.
Note: Support for the legacy .NET Framework 4.8 and older is deprecated in BricsCAD V26.
End-User Requirements
To load and run .NET-based plugins in BricsCAD V26:
- Install .NET 8 Desktop Runtime (x64).
You can download it from here.
- Ensure the installed runtime architecture matches the BricsCAD installation (x64).
- If a plugin fails to load with the following error, it means the file was blocked by Windows security:
Could not load file or assembly 'file:///<path-to-file> or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)To fix it, right-click the plugin DLL, go to Properties and choose Unblock.
Developer Requirements
Plugins built for .NET Framework 4.8 must be rebuilt using the .NET 8 SDK before they can be loaded in BricsCAD V26.
- Install the .NET 8 SDK (x64).
You can download it from here.
- Use the SDK-style project format introduced with .NET Core.
<Project Sdk="Microsoft.NET.Sdk"> <PropertyGroup> <TargetFramework>net8.0-windows</TargetFramework> </PropertyGroup> </Project> - Reference the appropriate BricsCAD managed assemblies.
- Rebuild the plugin using .NET 8.
Plugin Migration
Plugin migration instructions can be found in the README.txt file in the API samples folder of the BricsCAD install directory.
The default path of the README.txt file is:
C:\Program Files\Bricsys\BricsCAD V26 en_US\API\dotnet\README.txt