LightSwitch项目无法建立-2个奇怪的错误 [英] LightSwitch project failed to build - 2 strange errors

查看:100
本文介绍了LightSwitch项目无法建立-2个奇怪的错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不久前创建了一个LightSwitch应用程序,并且一切都进行了好几天. 它甚至没有问题地运行.

I've created a LightSwitch application not long ago, and it all goes OK for several days. It even ran without problem.

今天,我在项目中添加了一些评论.当我尝试运行它时,出现了两个错误,禁止我完成构建.

Today I have added a few comments in the project. When I try to run it, 2 errors appeared forbidding me to finish building it.

错误1类型查询"也使用域源"ApplicationData"中的名称查询'IdleAssetQuery". 错误2应用程序定义包含严重错误.

Error 1 The name 'Query 'IdleAssetQuery' in the Domain Source 'ApplicationData'' is also used by type 'Query'. Error 2 Application definition contains critical errors.

IdleAssetQuery是基于另一个表添加的最新查询.在创建它的那一天,项目进行了编译并顺利运行.但是现在它拒绝运行.

The IdleAssetQuery was the latest query added based on another table. On the day when I created it the project compiled and ran smoothly. But now it refuses to run.

考虑到我可能无意中弄了点什么,后来我在今天进行修改之前恢复了备份.它似乎运行正常-直到我尝试重建解决方案为止.出现了相同的错误.

Thinking that I may have unintentionally screwed something, I later restored a backup before I made the modification today. It seems to run properly - until I try to rebuild the solution. The same errors appeared.

我也曾尝试删除IdleAssetQuery,但该项目无论如何都不会生成.甚至还会添加另一个应用程序定义包含严重错误"错误.

I have also tried deleting the IdleAssetQuery but the project won't build anyway. It even adds another "Application definition contains critical errors" error.

有没有人可以帮助我解决这个难题?

Is there anyone who can help me to resolve this mystery?

仅供参考,我正在使用Visual Studio Pro 2013 版本12.0.30110.00更新1

FYI, I am using Visual Studio Pro 2013 Version 12.0.30110.00 Update 1

更新1:在最终创建IdleAssetQuery之前,我终于求助于还原了较旧的备份.将在尝试重新创建后进行更新.

Update 1: I've finally resorted to restoring an older backup before IdleAssetQuery was created in the first place. Will update after trying to get that re-created.

推荐答案

我今天确实遇到了同样的问题.昨天我正在从事LightSwitch项目,解决了一些问题.我完成了工作,建立了项目,一切都很好.今天,我想继续进行该项目的其他工作,但是突然出现了相同的错误-当然,这是我自己的一个疑问. 发生了什么?经过一段时间的尝试未能成功解决问题后,我决定回溯TFS历史中的一个变更集.仍然有一个错误,但是另一个错误更有用!现在我能够弄清楚发生了什么.

I did encounter the same problem today. Yesterday I was working on a LightSwitch project, solving some issues. I finished my work, built the project and everything was fine. Today I wanted to continue my work on other isseus of the project, but all of a sudden the same error appeared - but for one of my own queries of course. What happened? After some time trying to solve the problem without success, I then decided to go one changeset back in TFS history. There still was an error, but a different one with a more helpful error message! Now I was able to figure out what was going on.

似乎引起问题的查询是我用于报告的查询(对于LightSwitch,使用DevExpress XtraReports).问题是我试图为报表查询中的参数设置一些标准值,但无法弄清楚代码的位置.我找到正确位置的错误尝试之一必须在查询的客户端lsml文件(project-folder/Client/MyProject/ApplicationData/Query)中添加了一些XML(< QueryOperation> ...</QueryOperation>) .lsml). 我删除了这部分XML,然后重新加载并重建了该项目-一切都再次正常运行.因此,我在TFS中改回了项目的当前版本,并再次从查询的lsml文件中删除了XML.现在,该项目可以构建并再次运行,而不会出现问题.

The query that seemed to cause the problem was a query I used for reporting (with DevExpress XtraReports for LightSwitch). The problem was that I tried to set some standard values for parameters in the report query, but couldn't figure out where to put the code. One of my wrong attempts to find the right place must have added some XML (<QueryOperation>...</QueryOperation>) to the query's client-side lsml-file (project-folder/Client/MyProject/ApplicationData/Query.lsml). I removed this bit of XML and reloaded and rebuilt the project - and all was working fine again. So, I changed back to the current version of my project in TFS and once again removed the XML from the query's lsml-file. The project now builds and runs again without problems.

当然,问题的根源可能与我的不完全相同,但我想可能很相似.无论如何,我希望这能给遇到相同问题的任何人一个提示!

Sure, the source of your problem might not be exactly the same as mine - but it might be quite similar, I guess. Anyway, I hope this will give a hint to anyone who encounters the same problem!

这篇关于LightSwitch项目无法建立-2个奇怪的错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆