Extension Verify Fail with .NET Due To Using C# 6 Features

Extension Verify Fail with .NET Due To Using C# 6 Features

  

Using :

OutSystem Studio 10.0.603.0

Visual Studio 2017 with .Net Framework 4.5.2 as target for my project


We encourage a problem using outsystem extensions tool to integrate with already exist C# libraries made by another team.

The scenario:

  • We made a new extension and set its type to be .Net then open visual studio
  • Add the C# code to the project
  • Build the solution (build success)
  • Close visual studio
  • In Outsystem extension tool, we press verify button then we get compilation errors

Problem:

After more investigation, we get that the errors appear when using some code style from C#6

Example of code samples that exist in C# 6 :

  • Auto Property initializers

public decimal ExtraPrice {get; set;} = 0.25 m

  • nameof property

nameof(input) as nameof(MyEnum.FooBar)) returns “FooBar”

So please tell us how to upgrade the C# version of OutSystem extension to be 6.

Hi.

Have you tried to collect the C# 6 specific code and rewrite it for the 4.* versions syntax?

That shouldn't be difficult and would be more version proof.

Gonçalo Martins wrote:

Hi.

Have you tried to collect the C# 6 specific code and rewrite it for the 4.* versions syntax?

That shouldn't be difficult and would be more version proof.

I tried to change some of the errors to old code format and the error disappeared but to changing the full error list will take time and it's out of project scope and budget. so Please tell me if there another way?