简体   繁体   English

编译使用SubSonic库的WinForms项目时出错

[英]Error when compiling a WinForms project that uses SubSonic library

The code generation is working but I get the following errors when I try to build the project: 代码生成正在运行,但是在尝试构建项目时出现以下错误:

Error 4 Source file '...Project Path...\\Structs.cs' could not be opened ('Unspecified error ') PPSGenerator Error 5 Source file '...Project Path...\\Context.cs' could not be opened ('Unspecified error ') PPSGenerator Error 6 Source file '...Project Path...\\ActiveRecord.cs' could not be opened ('Unspecified error ') PPSGenerator Error 7 Source file '...Project Path...\\StoredProcedures.cs' could not be opened ('Unspecified error ') PPSGenerator 错误4无法打开源文件“ ...项目路径... \\ Structs.cs”(“未指定错误”)PPSGenerator错误5无法打开源文件“ ...项目路径... \\ Context.cs”已打开(“未指定错误”)PPSGenerator错误6源文件“ ...项目路径... \\ ActiveRecord.cs”无法打开(“未指定错误”)PPSGenerator错误7源文件“ ...项目路径...” \\ StoredProcedures.cs'无法打开(“未指定错误”)PPSGenerator

I'm using VS2010 on a Windows 7 64 bit machine. 我在Windows 7 64位计算机上使用VS2010。 Project is targeting Framework 3.5... any ideas? 该项目针对的是Framework 3.5 ...有什么想法?

Also noticed the following warnings, but not sure that these are as important: 还注意到以下警告,但不确定这些警告是否同样重要:

Warning 1 The C# 2.0 and C# 3.5 compilers are no longer supported. 警告1不再支持C#2.0和C#3.5编译器。 Templates will always be compiled with the version 4 compiler instead of 'v3.5' as specified. 模板将始终使用版本4编译器而不是指定的“ v3.5”进行编译。 ...ProjectPath...\\Structs.tt 1 4 ... ProjectPath ... \\ Structs.tt 1 4

Warning 2 Multiple template directives were found in the template. 警告2在模板中找到多个模板指令。 All but the first one will be ignored. 除了第一个以外的所有内容都将被忽略。 Multiple parameters to the template directive should be specified within one template directive. 应该在一个模板指令中指定模板指令的多个参数。 ...ProjectPath...\\Settings.ttinclude 1 4 ... ProjectPath ... \\ Settings.ttinclude 1 4

Warning 3 Compiling transformation: The variable 'parameters' is assigned but its value is never used ...ProjectPath...\\SQLServer.ttinclude 92 15 警告3编译转换:分配了变量'parameters',但从未使用过它的值... ProjectPath ... \\ SQLServer.ttinclude 92 15

Thanks! 谢谢! Mike D 迈克·D

BEGIN red faced answer to my own question 开始对我自己的问题回答

Ok, I originally dragged the files into my project root, then went out to the file system and deleted those files and dragged the files into my project in the Model folder. 好的,我最初将文件拖到我的项目根目录中,然后转到文件系统并删除了这些文件,然后将文件拖到了Model文件夹中的我的项目中。 for some reason the project was still looking for the files that were in my project root. 由于某种原因,该项目仍在寻找我项目根目录中的文件。 Because I deleted them on the file system I assume that Studio didn't get the memo and was still trying to compile them. 因为我在文件系统上删除了它们,所以我认为Studio没有得到备忘录,并且仍在尝试对其进行编译。

So happy that my first post on StackOverflow was a complete fustercluck. 很高兴我在StackOverflow上发表的第一篇文章完全是一篇fustercluck。

END red faced answer to my own question END红脸回答我自己的问题

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM