Hi, we have updated from 10.0.0.1589 to 10.0.0.1609 and can not use code created by rodl2code.exe
I can’t find any similar problems. I want to understand if we are doing something wrong or if it’s a rodl2code.exe problem and everyone has a similar problem.
public class TRDAddress_Activator : object, RemObjects.SDK.ITypeActivator
{
public TRDAddress_Activator()
{
}
public object! CreateInstance()
{
return new TRDAddress();
}
}
And the following errors on the build project:
‘TRDAddress_Activator’ does not implement interface member ‘ITypeActivator.CreateInstance()’
Invalid token ‘!’ in class, record, struct, or interface member declaration
thank you very much, in version 10.0.0.1589 there was no codedom option.
maybe you can explain in simple words what is generated now without this option? I couldn’t find anything related to rodl2code.exe and codedom
Microsoft Visual Studio Enterprise 2017 15.8.6
Microsoft Visual Studio Enterprise 2022 (64-bit) 17.13.6
Microsoft (R) Visual C# Compiler version 4.13.0-3.25167.3 (73eff2b5)
I have this same problem. I am not using rodl2code.exe but Service Builder. I select the option “CodeGen, C# for .NET” and the generated files include the ITypeActivator referencias and object!in the CreateInstance() declaration. Both produce this kind of errors in VisualStudio (Professional 2022, Version 17.13.6):
CS0535 'TAgenciaTS4_Activator' does not implement interface member 'ITypeActivator.CreateInstance()'
CS1519 Invalid token '!' in class, record, struct, or interface member declaration
CS1520 Method must have a return type
The only way to workaround this is to use the old codegen option. I am also on 1609.