I have a problem when I want to publish a web application on Visual Studio 2017.
As a foreword: I moved from one Notebook (Win 7) to a notebook (Win 10) recently. I restored missing nuget packages.
I can run the application. But when I want to deploy to via file system or deployement package I get the following error:
Copying file fonts\glyphicons-halflings-regular.svg to obj\Debug\Package\PackageTmp\fonts\glyphicons-halflings-regular.svg failed. Could not find file 'fonts\glyphicons-halflings-regular.svg'.
My structure is:
/Content
/Content/fonts
/Content/css
and the "fonts" folder contains the missing file.
Can aynone help me out here and give me some hints what I need to check for that?
The application is MVC 5, asp.net 4.5.
Thanks in advance.
答案 0 :(得分:0)
错误显示“正在将文件fonts \ glyphicons-halflings-regular.svg复制到...”,这意味着解决方案正在尝试在应用程序根目录下的fonts文件夹中查找文件。但是,根据您的结构,fonts目录位于“ Content”文件夹中。您可以将字体文件夹移到根目录中,也可以从csproj文件中排除丢失的文件。