Installation
The Eriksson Beam API is distributed as a local NuGet package. This guide covers the different ways to install it in your project.
Prerequisites
- Visual Studio 2019+ or VS Code with C# extension
- .NET Framework 4.7.2+ or .NET 6+
- Eriksson Beam desktop application installed
Installation Methods
Option 1: Visual Studio Package Manager (Recommended)
- Open your project in Visual Studio
- Right-click on your solution in Solution Explorer
- Select Manage NuGet Packages for Solution...
- Click the gear icon (Settings) in the top-right
- Click Add (+) to add a new package source
- Set Name to
ErikssonBeamLocal - Set Source to the folder path containing your
.nupkgfile (e.g.,C:\Packages\ErikssonBeam) - Click OK
- Select your new package source from the dropdown
- Search for
ErikssonBeamClientAPI - Install the package
Option 2: .NET CLI
Add the local package source and install the package:
# Add the local package source (run once)
dotnet nuget add source "C:\Packages\ErikssonBeam" --name ErikssonBeamLocal
# Install the package
dotnet add package ErikssonBeamClientAPI
Option 3: NuGet.config File
Create a nuget.config file in your solution directory:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
<add key="ErikssonBeamLocal" value="C:\Packages\ErikssonBeam" />
</packageSources>
</configuration>
Then install via the Package Manager Console:
Install-Package ErikssonBeamClientAPI
Option 4: PackageReference (Manual)
Add directly to your .csproj file:
<ItemGroup>
<PackageReference Include="ErikssonBeamClientAPI" Version="1.0.0" />
</ItemGroup>
Ensure your nuget.config includes the local source path.
Verify Installation
After installation, verify the package is correctly referenced:
using ErikssonBeam.API.BeamClient;
using ErikssonBeam.API.BeamDesigner;
// If this compiles without errors, installation was successful
Project Configuration
Target Framework
The API requires .NET Framework 4.7.2 or later, or .NET 6+:
<!-- .NET Framework -->
<TargetFramework>net472</TargetFramework>
<!-- .NET 6+ -->
<TargetFramework>net6.0-windows</TargetFramework>
Platform Target
The API requires x86 platform due to dependencies:
<PlatformTarget>x86</PlatformTarget>
Or in Visual Studio: Project Properties > Build > Platform target > x86
Dependencies
The API package includes these dependencies (automatically installed):
Newtonsoft.Json- JSON serializationMicrosoft.Extensions.Logging.Abstractions- Logging interfaces
Troubleshooting
Package Not Found
If the package isn't found after adding the source:
- Close and reopen Visual Studio
- Clear the NuGet cache:
dotnet nuget locals all --clear - Verify the package source path is correct
Platform Target Error
If you see runtime errors about missing assemblies:
- Ensure your project targets x86 platform
- Check that all projects in your solution use the same platform target
Version Conflicts
If you encounter version conflicts with Newtonsoft.Json:
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
Next Steps
Once installed, proceed to License Setup to configure your API key.