无法将许可证文件转换为二进制资源



我有我的旧Web Applicatoin,在.Net Framework 2.0中开发。现在我试图在VS2012中打开它,它给了我以下错误…

Could not transform licenses file into a binary resource.  (1) : error LC0004 :
Exception occurred creating type 'Infragistics.WebUI.WebDataInput.WebDateTimeEdit, 
Infragistics.WebUI.WebDataInput.v5.1, Version=5.1.20051.37, Culture=neutral, PublicKeyToken=7dd5c3163f2cd0cb System.ComponentModel.LicenseException: 
Unable to locate license assembly.at System.ComponentModel.LicenseManager.CreateWithContext(Type type, LicenseContext creationContext, Object[] args)
at System.Tools.LicenseCompiler.GenerateLicenses(String fileContents, String targetPE, ITypeResolutionService resolver, DesigntimeLicenseContext ctx)'

下午好

当我们分支了一个解决方案(svn)用于在需要时修补生产时,这种情况就发生在我身上。当我从分支构建解决方案时,它给了我一个类似的错误,谈论基于索引的(零)等等等等。事实证明,我的.licx文件上有一个空白行导致了错误。删除空行修复了这个问题。

只是为了帮助别人。

更新2022-11-11:这在VS 2022中不再适用于我。我现在必须在VS 2019中打开解决方案,清空该文件的内容并重建解决方案,将内容放回去并再次重建。这样做之后,我就可以进行"重建"了。在VS 2022。如果有人找到更好的解决方案,请告诉我,因为我不打算永远在我的机器上保留VS 2019 =)

认为,

我已经删除了许可证文件,它为我工作

删除了额外的行,但它不起作用。

我删除了BIN文件夹并进行了"重建"。

我从许可证中剪掉了所有的行。licx并编译项目,然后我将之前剪切的内容粘贴到许可证中。

最新更新