Code generation not working
No edit summary
(Updated Edited template to July 12, 2025.)
 
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<message>Write the content here to display this box</message>


==== Code Generation Not Working for One or Several Classes ====
==== Code Generation Not Working for One or Several Classes ====
The project file in Visual Studio should have dependencies defined.
The project file in Visual Studio should have dependencies defined:
  <Compile Include="EcoProject1\Class1.cs" />
  <Compile Include="EcoProject1\Class1.cs" />
     <Compile Include="EcoProject1\Class1.eco.cs">
     <Compile Include="EcoProject1\Class1.eco.cs">
Line 8: Line 9:
If this structure isn't correct, for example, due to a merge error in source control, do this to correct it:
If this structure isn't correct, for example, due to a merge error in source control, do this to correct it:
# Exclude ('''not delete!''') all the generated class code files, both the .cs and the .eco.cs files.
# Exclude ('''not delete!''') all the generated class code files, both the .cs and the .eco.cs files.
# Code generate everything again with "Ctrl + <the C# button>"
# Code generate everything again with '''"Ctrl + <the C# button>"'''
No files will be overwritten, but the correct VS structure will be regenerated.
No files will be overwritten, but the correct VS structure will be regenerated.


See also: [[Codegen failed]], [[Codegen Issues .net standard]]
See also: [[Documentation:Codegen failed|Codegen failed]], [[Documentation:Codegen Issues .net standard|Codegen Issues .net standard]]
 
[[Category:Error messages]]
[[Category:Error messages]]
{{Edited|July|12|2025}}

Latest revision as of 05:47, 20 January 2025

This page was created by Lars.olofsson@mdriven.net on 2019-10-18. Last edited by Edgar on 2025-01-20.


Code Generation Not Working for One or Several Classes

The project file in Visual Studio should have dependencies defined:

<Compile Include="EcoProject1\Class1.cs" />
   <Compile Include="EcoProject1\Class1.eco.cs">
     <DependentUpon>Class1.cs</DependentUpon>
</Compile>

If this structure isn't correct, for example, due to a merge error in source control, do this to correct it:

  1. Exclude (not delete!) all the generated class code files, both the .cs and the .eco.cs files.
  2. Code generate everything again with "Ctrl + <the C# button>"

No files will be overwritten, but the correct VS structure will be regenerated.

See also: Codegen failedCodegen Issues .net standard