KufCad

C# plugins (KufNET)

Ribbon: Manage ▸ ApplicationsCommand: NETLOAD, NETLISTAlias: NETLOAD

KufNET runs C# (.NET 8+) plugins inside KufCad with an API shaped like the AutoCAD .NET API (change the using lines to port an AutoCAD plugin). It needs the .NET 8 runtime or newer installed; KufCad only starts .NET the first time you load a plugin.

CommandWhat it does
NETLOADPick a DLL and load it; its [CommandMethod] commands appear at once
NETUNLOADUnload a plugin
NETRELOADUnload then load again (rebuild the DLL without restarting KufCad)
NETAUTORELOADOn: a DLL changed on disk reloads the next time one of its commands runs
NETLISTReport the .NET status and loaded plugins
NETLIST
Figure 14.1 — NETLIST reporting that .NET is available on this machine but not started yet.

The NETLOAD file dialog belongs to the operating system so there is no picture; pick the .dll built from your plugin project. Plugins built for AutoCAD (referencing AcMgd, AcDbMgd…) are refused: recompile against KufCad.Core. Samples are in samples/dotnet (HelloKuf, AcadPortDemo, AutomationClient); the plugin guide is kufnet/docs/getting-started.md.

A .NET plugin runs with KufCad's full permissions: load only plugins you trust. SECURELOAD applies as for LISP. WinForms / WPF cannot be used inside KufCad; plugin dialogs use KufCad's own renderer (so they work on Windows and macOS). Loading a real plugin was not tested while writing this guide because the file dialog is an operating-system one.