Specified condition "$(CleanWPPAllFilesInSingleFolder)" evaluates to "" instead of a boolean. - visual-studio-2013

At first my only problem was that while trying to publish I clicked on Start Preview and got this error:
Specified condition "$(CleanWPPAllFilesInSingleFolder)" evaluates to "" instead of a boolean.
then searching for solution on the internet made my problem worse to the point that I can not load the project any more with the same error.
C:\Users\Syed Farjad Zia Zaid\documents\visual studio 2013\Projects\SageInventrica\SageInventrica\SageInventrica.csproj : error : Specified condition "$(CleanWPPAllFilesInSingleFolder)" evaluates to "" instead of a boolean. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\Web\Microsoft.Web.Publishing.targets
Naturally I tried to search for a solution and tried all possible combinations of deleting .user, .suo, closing and opening Visual Studio etc but nothing helped me except for deleting this File:
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\Web\Microsoft.Web.Publishing.targets
But then I can not publish a zip getting the error:
The target "Package" does not exist in the project.
and when I try to publish to Server Directly I get the error:
The target "MSDeployPublish" does not exist in the project.
I have been trying to find the solution for this for about 2 days now. May be I am not looking at the right places but I really need help to fix this...
Thanks

I fixed this problem by restarting Visual Studio as Admin, and publishing again, but making sure NOT to preview the publish actions.

Related

Get Latest will give an error if file is Not downloaded

When Source Control Explorer shows that a file is Not Downloaded, selecting Get Latest Version will result in the following:
I don't remember this happening in the past. Is there a way to prevent this?
This kind of error or situation may occur when using "Get Latest Version" after someone else has just added a new item to source control.
For example, it seems to be triggered by multiple people working on the same solution at the same time. So if you check stuff in, then the other user gets this message when doing a "Get Latest". It appears Visual studio is detecting the files that were checked in by the other user and then pulling them in the background but not updating the local workspace data, so when you do a Get Latest, the files already exist, but it gets confused as to the source control status and throw this because it's confused.
One solution for this issue is closing your Visual Studio and clear TFS cache. Then open the Visual Studio and get latest for this file again.
Another way is directly removing the work space and create a new one then tfs will prompt you to download everything again. https://msdn.microsoft.com/en-us/library/ms181386(v=vs.100).aspx This should do the trick.

unknown MSBuild failure on osx

I have been working on a xamarin ios application with MVVMlight framework.
It was working without any problem but suddenly I am getting the following error
Unknown MSBuild failure.Please try the building the project again
Herewith I have attached the screenshot of build log
When I click the error it leads to the .csproj file
I have verified the the xml is syntactically right no presence of any special character that can cause any xml problem
So far I have tried clean & build,removing the obj and bin manually,restarting the xamarin.But nothing works so far.
The problem is not seen in Visual studio though
Any suggestions to solve the problem is welcome
There was a space in one of the directory name in the path.
I replaced the space with %20 for directory name on Finder and it started working.

How to clear Visual Studio workspace

I have a workspace in VS2015 (same problem in 2013) that I'm trying to completely remove and start fresh with a copy from the server. To clarify, I want none of the files or changes that currently exist and I want to start completely fresh with the server copy of all files. I don't know how to correctly do this, however. I've deleted the workspace, the actual files that the workspace pointed to, and I've cleared the cache locations below, but VS still shows that the workspace exists and won't fix itself. In fact, it still shows the mapping even though I've triple-checked that it's deleted.
I'd like to avoid using devenv /reset since I'm pretty customized and I don't want to fix all of it, but I'll do it if it's unavoidable. How can I accomplish this?
Locations cleared/deleted:
%LocalAppData%\Temp\<all VS files/folders>
%LocalAppData%\Microsoft\Team Foundation
%LocalAppData%\Microsoft\VisualStudio\<version>\ComponentModelCache
On the window where you can get a specific change set from TFS, get the changeset with id "1". This is the situation just before the project was created - empty!
Right mouse om project node in solution explorer
Source Control > Get specific version
Version type "change set"
Input change number "1" (without quotes)
Click "Get"

VS2013: Error Loading Solution ('JavascriptWebExtensionsPackage did not load correctly')

Visual Studio 2013 Professional just started throwing this error on me, in the middle of switching solutions. A full reboot of the computer didn't resolve it.
Here's the error I see when I try loading a solution:
Now, when I go look at the log file it suggests, I see this:
SetSite failed for package [JavaScriptWebExtensionsPackage]
End package load [JavaScriptWebExtensionsPackage]
If I click "Yes" to continuing to show the message, and try loading up a file in the solution -- I get this message:
Telling me that No EditorOptionDefinition export found for the given option name: Tabs/ConvertTabsToSpaces - Parameter name: optionId.
I really do not know what to make of this. I didn't do anything except check in some files to TFS (which I do dozens of times a day, a week, a year). The only thing I ever did differently that I never did before was attempt to view Source>Annotations on a file (I've never did that in my life with TFS/VS) about 10 minutes prior - but that worked fine and was just ducky.
So - any ideas why I'm getting this message - and how to resolve it without a fullblown re-install?
So -- after posting this and adding that last screenshot (the No EditorOptionDefinition export... business) -- I decided to google on that phrase as well (the other key phrases brought me nothing).
It brought me to this page:
No EditorOptionDefinition Export Found Error
Which actually fixed the problem.
In short:
Close Visual Studio
Open the %UserProfile%\AppData\Local\Microsoft\VisualStudio\<version>\ folder
Rename or delete the ComponentModelCache folder
Restart Visual Studio.
I had the same problem, All i did was went to Control Panel and ran a Repair on VS 2013. Waited for it to complete and restart my computer and it worked.
In my case above solution not work out but when I tried to delete everything from
%LocalAppData%\Microsoft\VisualStudio\14.0\
from above location then I restarted visual studio 2015 then it works fine.
Hope anyone having this issue may resolve deleting everything from 14.0 directory
thank you
I had the same experience. Deleting %LocalAppData%\Microsoft\VisualStudio\14.0\ worked fine. I could not delete for permission reasons so had to delete from command line all files in 14.0.

Xap packaging failed. Object reference not set to an instance of an object

I'm getting this error message on my PC when I try to build my Windows Phone app:
Xap packaging failed. Object reference not set to an instance of an object
I'm using Dropbox. On my laptop, It works perfectly fine and I can debug etc...On my PC however, I can't.
I tried many things such as:
Delete obj/Debug Folder
Check for files which are missing on the Solution Explorer
So far, nothing has helped.
Any idea how I can fix this?
You should check, in every folder of your project, for missing files or wrong references.
You can get this problem just with a single missing image, if its Build Action property is set to Content or similar...
Check your files and then Rebuild your project!
This can happen if a file is removed from the disk itself, but not from the Solution through Visual Studio. Delete the file through Visual Studio (it should be marked with a little yellow hazard icon) and Rebuild.
Credit to Andreas Hammar via http://blog.jayway.com/2011/06/03/wp7-build-error-xap-packaging-failed/ - his solution worked for me.
I am adding this reply because although the problem with app icons is covered in brief in some of the answers above, I wanted to give exact steps since it just happened to me. I got this error and then found this web page:
Xap Packaging Error
It turned out that my App icon file name was wrong due to a rename. I double-clicked on WMAppManifest.xml, found in the Properties folder, to open the editor for that file. I simply used the button to update the App Icon, re-found the file and selected it, and the error went away after rebuilding the project.
The problem lies in your startup object in your Application. I have met this error to many times.
It usually happens when I change the name of my class/namespace Application class. Or it might even be conflicting with your dropbox locations.
To Fix this.
Right click your main project or Alt+Enter
Go to the silverlight tab and set your startup object
Try the following:
Have Visual Studio closed
Download all your files to your computer
Delete Bin and obj folders completely.
Open the .sln
Rebuild
If if fails expand the References in te Solution explorer and make sure all your dll's are found. If a dll have a yellow exclamation point that means its not found. I'm thinking that one of your references are set to an absolute path on your laptop and that's missing on your PC.
If someone comes across this post and still has the issue I had where XAP packaging failed and that VS2012 can not find the file then check for spaces in the file name.
I had the issue where my tiles were "tilename 99.png" and it keep giving me the XAP packaging failed message. So I finally changed the file name to "tilename_99.png" and it worked.
Hope this helps someone in the same predicament.
In my case, I'd accidentally moved Background.png to a resource folder. Moved it back and it worked!
In my case, this error didn't go away even after trying all the above methods. Actually I had renamed the ApplicationIcon.png to "xyz.png". And reverting this, fixed the issue.
One more possibility is that you have a wrong path to an image in the project/options/Application dialog (icon, bg image, etc).
I had this error message, after some frustration I look in the obj folder, is was no part of the solution(but visual studio need it) but I had some conflicts files with dropbox. I deleted the obj folder rebuild, visual studio recreates the folder and the content of it and problem solved.
Ahh finally found my problem.
I'm using Visual Studio 2012, which doesn't always point out the "missing" file and makes it a little harder to fix.
MY SHORT SOLUTION
Relink the "linked" configuration file in the main project. It is a linked file because the original file remains in a referenced assembly, not in the current assembly. The file wasn't marked YELLOW so it wasn't obvious that it would be the problem, but when I double clicked on it, it failed to open, so I knew this was the problem file.
The silverlight application itself had a "linked" file called "ServiceReferences.ClientConfig" which contains information needed by a referenced project to make a web service call.
So the main project didn't have the web service reference itself, but it referenced a project which did, which is why it linked the "ServiceReferences.ClientConfig" file.
MY LONG SOLUTION
Keep rebuilding the main project file, and commenting out, and excluding project by project, file by file, until you CAN build the main project again. At that point it should be clear(er) which part of the solution is causing the problem.

Resources