Using Projects with Synergy .NET

.NET applications are made up of assemblies. An assembly can be an executable (.exe) or a class library (.dll). A class library is a collection of subroutines, functions, and/or classes that are invoked from other class libraries and executables. To develop Synergy .NET assemblies, you’ll use Visual Studio to create solutions and projects, and you’ll use Visual Studio build features (which run the Synergy .NET compiler behind the scenes) to build assemblies from these projects. See Synergy files, projects, and solutions for more information.

1. Synergy .NET assemblies are built from Visual Studio projects.

Synergy .NET assemblies are built from Visual Studio projects

For each of the assemblies that will constitute your application, you’ll need to create a Visual Studio project from one of the Synergy/DE project templates. You’ll then add Synergy DBL code, references to other assemblies as necessary, and other items to your project. For details, see the following:

One of the advantages to using .NET is that Synergy assemblies can use .NET Framework classes and can interoperate with assemblies written in other .NET languages (e.g., C#; see figure 2 below). So in addition to invoking .NET Framework functionality in your code, you can include Synergy projects in solutions for other .NET languages, and you can include projects for other .NET languages in Synergy solutions.

2. Synergy projects can be part of non‑Synergy solutions and vice versa.

Synergy projects can be part of non‑Synergy solutions and vice versa

For more information, see the following:

Note that Synergy .NET projects cannot reference traditional Synergy projects and vice versa. (Although routines accessed via xfServerPlus can be converted for native .NET access. See Converting xfServerPlus routines for native .NET access.)

Using .NET Standard libraries and targeting multiple platforms

With Synergy .NET, you can target multiple platforms by including projects for each type of platform in your Synergy solution. If possible, it's best to include common code in a .NET Standard library and then put platform-specific code in platform-specific class libraries and executables. For information on creating .NET Standard libraries, see Developing .NET Standard libraries.