Can't start/debug application in VS2013 anymore - visual-studio-2013

Since today I can't debug any applications anymore.
If I want to start the debug session, I get the error message
error while trying to run application: invalid pointer
It doesn't depends on the project, this behaviour appears in every project/solution.
What i've already tried:
Reset VS settings
repair Visual Studio
complete reinstall of visual studio
Changed Build Platform to x86/x64
Enabled native code debugging

If you press Ctrl-F5 to run the application, you won't get the error and the application will start, but you can't do debug, so this isn't a real solution.
The only way to solve the problem is to update Visual Studio: I had the same problem (WPF application), which was solved by the Microsoft Visual Studio 2013 Update 4.

If you're running VS 2013 and get an error that's pointing to the body tag, try adding this to the web.config under
<appSettings>
<add key="PageInspector:ServerCodeMappingSupport" value="Disabled" />
That key disables browser link which currently isn't playing nice.

Related

"Opening and creating websites on iis requires running visual studio under an administrator account"

I'm seeing this error in a pop-up window when attempting to run/debug my web project from Visual Studio
The following error occurred when trying to configure IIS Express. Opening and creating websites on iis requires running visual studio under an administrator account
This happened completely out of the blue. One second I was working as normal, regularly going in and out of debug in my browser, then this error pops up. It happens when attempting to run any web project, and it doesn't matter if it's in debug, release mode or what.
Stuff I've tried:
Run Visual Studio as Administrator
Uninstall/Reinstall IIS Express (via "Turn Windows Features On or Off" in Control Panel)
Update Visual Studio
Delete project's .vs folder
But still the error persists.
Is there anything else I can reinstall, update or otherwise check?
Thanks.
Solved it by going through a day of hell, and to be honest the 'solution' was very brute force...
TL;DR: Fully deleting and reinstalling Visual Studio seemed to do the trick.
Since the usual methods weren't working, I tried a full reinstall of Visual Studio. That didn't help. I then tried a System Restore. That made everything far worse, with my project showing about 500 error messages!
I then undid the System Restore, completely deleted all traces of Visual Studio from my computer, reinstalled everything, then tried VS2019 preview edition, tried 2017 edition again, uninstalled and reinstalled NetCore 2.0, 2.1, 2.2... all just to get around the minefield of error messages I'd created for myself.
In the end I just needed to do a full NuGet clear and restore then run dotnet restore --force in the NPM console, after which all those error messages were gone. As well as this, the original IIS Administrator error was gone too, presumably fixed via the original reinstall of Visual Studio.
Lost a whole day to this quagmire.
Downloading & Installing IIS Express from Microsoft worked for me. No need to update VS or remove/re-add the project.

Double-click this warning

I have just started working with Xamarin this week. I created a new "Mobile App" in Azure and downloaded from Azure a sample Xamarin Forms app. When I try opening it in Xamarin Studio, I get this message:
Found conflicts between different versions of the same dependent assembly. In Visual Studio, double-click this warning (or select it and press Enter) to fix the conflicts; otherwise, add the following binding redirects to the "runtime" node in the application configuration file...
There are two problems with this message. First, these warnings exist only in Xamarin Studio. The same solution opened in Visual Studio 2015 does not have this warning - and so it is not possible for me to "double-click" it in Visual Studio.
Second, the full text of this Xamarin Studio warning is virtually inaccessible because there is no way to copy it. What portion of the warning you see above, I had to transcribe. The rest of the warning is VERY long, and Xamarin Studio is acting as if it expects me to copy it somehow. But the only way to copy it...is again to spend twenty or thirty minutes transcribing it. Certainly I must be misunderstanding how to use Xamarin Studio. Here is a screen shot:
Is there a Xamarin Studio keyboard shortcut or trick that would allow me to capture this warning? And is it normal for Xamarin Studio to request problems to be fixed through Visual Studio? Why does the warning not exist in Visual Studio?
This solution also doesn't build in Visual Studio 2015. I don't get any warnings (unfortunately?), and in fact I don't appear to have any build errors either. However, when it attempts to deploy (Windows phone emulation) it gives me a variety of errors. Most of them are of this variety:
The name 'X' does not exist in the current context.
I'm baffled by this, because the symbols it names are indeed missing. So why does it build successfully?
This is not a problem in visual studio or xamarin studio.
If the device on which you are trying to deploy the build,already has an apk file installed(not from your work station), you will get this issue.
To resolve this uninstall it from the device and also from the package manager and then try to deploy the build.
I hope it will help.

set property 'system.windows.resourcedictionary.deferrablecontent' threw an exception

I'm running Visual Studio 2012, when I add a new File/Reference to a project the message box appears showing the error message
set property 'system.windows.resourcedictionary.deferrablecontent' threw an exception
I read an MSDN article suggesting to run the command devenv /resetuserdata on visual studio command prompt to resolve this problem, tried it but didn't work for me. In fact the command prompt shows the Unknown Error message.
Some addins cause this issue for me so have had to workaround it whenever it occurs:
In Vis studio -
Tools > Options > Environment > Add-in Security, uncheck 'Allow Add-in components to load', OK
Restart vis studio
The error shouldn't occur anymore, so go back to
Tools > Options > Environment > Add-in Security and re-check Allow Add-in components to load, OK
To be specific, I get this error when trying to add files to projects and manage Nuget Packages.
Update
I now make a point of opening
'Tools > Nuget package manager > Manage nuget packages for solution'
whenever I open up a new instance of Vis studio, before loading a solution, just to make sure the window loads properly
That way I know I won't get this issue.
In my case it was a style with the same key defined twice in a ResourceDictionary (WPF)
I have Windows azure tools for Microsoft VisulStudio 2013- v2.2 and Windows azure tools for Microsoft lightswitch VisulStudio 2013- v2.2.
I uninstall only Windows azure tools for microsoft lightswitch vs 2013 .
It's working fine...
I fixed it. The resolution was to remove the Windows Azure Tools for Visual Studio 2012 which I was not actually using, and the error went straight away.
In my case it was to first launch Visual Studio in safe mode. You can create a shortcut for visual studio with a target like this:
'"F:\Program Files\Visual Studio\VS2013\Common7\IDE\devenv.exe" -safemode'
Once launched in safe mode, you can remove the problematic extension via the Addin Manager. However, this wont work for some extensions, as the uninstall option might be disabled for certain extensions when running in safe mode, particularly if you have already uninstalled another extension in the same session.
In My case the problem was caused by Paradox Game engine, in which I had uninstalled it via 'Programs and Features' - which in return did not remove the extension which was originally installed via Nuget package. Uninstalling Paradox via "Programs And Features" left the extension itself still registered in Visual Studio, presumably causing a hidden NullReferenceException.
This issue can be caused by any extension that may have an error in it, or by extensions that were not properly uninstalled.
Also, see this article...
The mentioned issue can be resolved by simply restart the Visual Studio. :P
Also seem to be able to get around this by closing the project and vis studio instance, re-opening, then when the start page/open project screen appears selecting Tools > Extensions and Updates..., then pressing Close
Now open the project and the error doesn't get thrown when trying add files or manage nuget packages, weird.
Just annoying you have to remember to open Extensions and Updates each time...
Other wise make sure given Resourcedictionary.xaml path is correct or not
I had to remove Xamarin from Add/Remove Programs in Control panel and restart Visual studio to fix this.
I had this problem with My Devexpress Project in VS 2015
What finally worked for me was.
Close my solution,
Close Visual Studio,
Open Visual Studio,
Create a New dummy project,
Add a form to it,
Close and save the new project,
Reopen original project and all was ok.
for everyone else who are working in silverlight sdk environment with windows phone8 sdk.
The versions of sliverlight which are compatible with visual studio versions -
vs2012- sliverlight sdk 4
vs2013- silverlight sdk 5
I was integrating in vs2013 and as soon as I updated it with silverlight sdk 5, The errors went away.
In my case it was the Line Endings: you can have different formatting and by copy pasting some code one file got a different Line Ending. It was enough to File > Save As and then click the little arrow next to the save button.
Then click on save with encoding and choose the one you are using in all other files.
See Andrew Truckle's answer.
I hope this helps

How do I remove the popup about "The 'VSTS for Database Professionals' package did not load correctly."?

I'm not sure exactly when, my VS2010 started showing me the same error popup every time I loaded it. Clicking "No" has no effect, since the message will show up again each and every time I open VS.
I really don't see any adverse effect without this "VSTS for Database Professionals", but the error popup is getting annoying. Can anyone tell me how to disable it without having to uninstall anything?
---------------------------
Microsoft Visual Studio
---------------------------
The 'VSTS for Database Professionals' package did not load correctly.
The problem may have been caused by a configuration change or by the installation of another extension. You can get more information by running the application together with the /log parameter on the command line, and then examining the file 'C:\Users\peter.mounce\AppData\Roaming\Microsoft\VisualStudio\10.0\ActivityLog.xml'.
Continue to show this error message?
---------------------------
Yes No
---------------------------
Edited to add: I did a google search to see if anyone else had this problem, but the only cases are found are not applicable to my situation, since I have neither LightSwitch nor PostSharp installed.
I do have ReSharper 6.1, if it helps any.
Do you have .NET Framework 4.5 installed? If not, installing that can help with this popup. I have not investigated why, but this package appears to depend on .NET Framework 4.5 for some reason. Even if using Visual Studio 2010 (which does not even support 4.5).
From your log file, it appears Resharper is somehow interfering. Try uninstalling/repairing and seeing if that makes it better.
<entry>
<record>288</record>
<time>2013/04/11 18:30:06.996</time>
<type>Error</type>
<source>VisualStudio</source>
<description>SetSite failed for package [VSTS for Database Professionals]</description>
<guid>{068E2583-0872-403B-AF4C-6C2A8F2D8C3E}</guid>
<hr>80131522</hr>
<errorinfo>Could not load type 'System.Runtime.CompilerServices.ExtensionAttribute' from assembly 'JetBrains.Platform.ReSharper.Util, Version=6.1.1000.82, Culture=neutral, PublicKeyToken=1010a0d8d6380325'.</errorinfo>
</entry>
Visual Studio 2010 installation media: \WCU\DAC folder, find and run-install:
DACFramework_enu.msi
DACProjectSystemSetup_enu.msi
TSqlLanguageService_enu.msi
Reapply Visual Studio 2010 SP1
Details:
http://connect.microsoft.com/VisualStudio/feedback/details/532121/tons-of-package-did-not-load-correctly-errors
The solution is to reset the settings (in case something went wrong with the SQL side of installation):
1) Launch DOS in ADMIN mode (hold WindowsKey+X), Select "Command Prompt (Admin)"
2) Go to your developer studio folder, usually it's under "C:\Program File(x86)\Microsoft Visual Studio 10.0\Common7\IDE"
3) Reset the settings by typing:
devenv.exe /ResetSettings
4) Once done, close DOS, and then launch Visual Studio, the error should disappear.

Excel won't open/launch VSTO AddIn when running in debug mode of Visual Studio 2010

I had previously installed the VS11 beta, and had some issues with my Visual Studio 2010 instance, which you can see here how they were resolved: Excel AddIn Click Once deployment issue.
Now I have a code base which compiles/builds a vsto, which installs fine and runs fine in Excel 2010. However, when I remove the installed version from Excel, and try to run it directly through Visual Studio 2010, the AddIn does not get loaded into Excel when running in debug configuration mode, in release configuration mode it works fine. Any ideas on why this might be occurring? I've tried re-enabling it through Com AddIns, and a few other things with no luck.
I've found the issue which was not letting me run my project in 'Debug' configuration mode, though it worked in 'Release' mode. At some point, the AddIn, got hard-disabled (not sure if that's the term to use). At that point, trying to re-enable from within Excel doesn't do anything. Within the registry, there is a folder where disabled AddIns are flagged. I deleted all of the keys from this folder except for "(Default)" and now my AddIn works when launching from Visual Studio 2010 in 'Debug' mode.
HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Excel\Resiliency\DisabledItems
When you run through Visual Studio 2010 does it hits the breakpoint in the addin_startup event.
If not try to debug this way
Hope this helps you
You can reenable a hard-disabled Add-In with Excel
http://msdn.microsoft.com/en-us/library/ms268871(v=vs.80).aspx
I had the same problem with a Word VSTO, but there was no Resiliency\DisabledItems folder in my registry, so I think it was never hard disabled (as in #mservidio's solution). What worked for me was to edit the Manifest path in HKEY_USERS\<user key>\Software\Microsoft\Office\Word\Addins\<Add-In name> to reflect the 'Debug' path rather than the 'Release' path.
To find the right folder it might be easiest just searching for the Add-In name and checking that any Manifest keys refer to the Debug path.
I had the same problem in Excel.
The following worked for me:
Go to the following key....
HKEY_CURRENT_USER\Software\Microsoft\Office\15.0\Excel\AddInLoadTimes
see if your plug-in is listed. if so, delete it.
now run your app from Visual studio again.
This worked for me, hope it can help someone else.
I also had the same problem, what I didn't understand was :
Why I re-install Office 2016, I don't change my code neither VS setting but I get a cant load error message ?
After many many hours, repairing Office and VS and getting the same error message, I observed that the Addin was starting well in Release config, I started checking the difference between the both config in my code.
I found that debug config was targeting to x86 proc bug release to any cpu
So Office x64 didn't load x86 dlls (in my case)

Resources