Gen 8.6 - External programs that require a different version of .NET
search cancel

Gen 8.6 - External programs that require a different version of .NET

book

Article ID: 239283

calendar_today

Updated On:

Products

Gen Gen - Host Encyclopedia Gen - Run Time Distributed Gen - Workstation Toolset

Issue/Introduction

Started with a GEN 8.6 Web client program linked with an external C# program that has worked fine so far.  After some changes in the C# program, a change was made in Visual Studio's project Target Environment from .net framework 4.0 to .net framework 4.6.1 in order to support some reporting modules that are needed.

After that, The GEN Build Tool returned an error.

"The primary reference "CISW4" could not be resolved because it was built against the ".NETFramework,Version=v4.6.1" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.0". C:\Models\CIS.ief\c#\CISW.csproj]"

 

Environment

Release : 8.6

Component : Gen Build Tool

Resolution

Edit the Build Tool's build_lm_cs.scr script file to set the ResolveAssemblyReferenceIgnoreTargetFrameworkAttributeVersionMismatch element to true, as is suggested in the Microsoft article (https://devblogs.microsoft.com/devops/reference-could-not-be-resolved-error-when-validating-your-architecture-using-visual-studio-architecture-modeling-tools/).
Search the script file for the section containing multiple <PropertyGroup> entries.  Insert the code below within the <Project> elements that contain the <PropertyGroup> entries.
 

<PropertyGroup>

<ResolveAssemblyReferenceIgnoreTargetFrameworkAttributeVersionMismatch>true</ResolveAssemblyReferenceIgnoreTargetFrameworkAttributeVersionMismatch>

</PropertyGroup>