I don't think that it is related to my template code. I get this error when I add <[System.Data]> at the top of an existing template.
I simply added <[System.Data]> to the top of defaultCode.lpt (SD.AdditionalTempaltes.DbEnditor.Net20 -> SD_DefaultCode).
<[System.Data]>
using System;
using System.Data;
using System.Configuration;
using System.Web;
...
When I generate the code I get an exception
Compilation of templates threw errors:
Error CS0234, at line: 14, pos: 14: The type or namespace name 'Data' does not exist in the namespace 'System' (are you missing an assembly reference?)
The generated code is:
using SD.LLBLGen.Pro.ApplicationCore.StoredProcedures;
using SD.LLBLGen.Pro.ApplicationCore.Templates;
using System.Collections;
using SD.LLBLGen.Pro.ApplicationCore.Entities;
using System;
using SD.LLBLGen.Pro.ApplicationCore.Tasks;
using SD.LLBLGen.Pro.LptParser;
using System.IO;
using System.Diagnostics;
using SD.LLBLGen.Pro.ApplicationCore.TypedLists;
using SD.LLBLGen.Pro.DBDriverCore;
using System.Text;
using SD.LLBLGen.Pro.ApplicationCore.TypedViews;
using System.Data;
using SD.LLBLGen.Pro.ApplicationCore;
using SD.LLBLGen.Pro.GeneratorCore;
using System.Collections.Generic;
using System.ComponentModel;
line 14 is using System.Data;