VS2012 Javascript Debugging Won't Work - debugging

For the last 2 days I have had a right pigs ear of a problem that I just have not been able to get past.
Any time I try to debug an Windows 8 store JavaScript app using VS2012 on my laptop I get the following error:
>Unable to start debugging 'C:\Windows\system32\wwahost.exe'.
>
>Microsoft Visual Studio Debugging Monitor (MSCVMON.EXE) failed to
>start. If this problem persists, please repair your Visual Studio
>installation vis 'Add or Remove Programs' in control panel.
This happens when I try to debug locally and in simulator.
This only happens for javascript projects, all other types of projects work fine.
So far the steps I have taken are:
repaired installation
installed update 1
Added all application packages to program files (x86)\Common Files\Microsoft Shared\VS7Debug on security tab.
uninstalled and re-installed
Nothing has worked.
Interestingly this error is about remote debugging which I am not trying to do, I didn't have remote debugging installed for 2012 but it was installed on my system for VS2008.
I installed it for VS2012 and opened the monitor while I tried to debug and nothing showed in the log.
I did an install using same VS2012 DVD on a fresh win8 desktop installation and it has no issues it all works fine although it did ask me on first run to set the permissions (I cant remember if it did this on my laptop).
I think the problem came when installing on my laptop it asked me if I wanted to import setting from previous versions of Visual Studio and I said yes.
I have done constant internet searching on this topic for last 2 days and some people are saying the problem is caused by VS2012 trying to open some VS2008 files but how to fix this is not clear.
When I uninstalled VS2012 and re-installed it didn't ask me if I wanted to import settings so I think I didn't fully un-install it (it still had a list of my recently accessed projects after the re-install).
Sorry for the long post but this has driven me crazy and I just cannot think of what to try next. Can anyone please help?

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.

Visual Studio 2015 Extensions Manager Index was out of range error

Env: Visual Studio 2015 Community Edition on Windows 8
Trying to open Tools --> Extensions and Updates results in the following error in a message box:
Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
Tried running as Admin, same result.
I've tried looking at the log but nothing mentions that error.
In the log there are 3 error entries related to extensions which could be related, they say the following:
Error loading extension: Could not find a part of the path 'C:\path\to\APPDATA\LOCAL\MICROSOFT\VISUALSTUDIO\14.0\EXTENSIONS\ZW2UF5JV.JVN\extension.vsixmanifest'.
The other 2 are identical except the odd string at the end is HQ1Y5EQD.TMG and 3KWE1LJF.Z1W.
Interestingly, just before those errors in the log appear, there is a line for each saying the extension was loaded successfully but if I try to go to the path it's got listed, it doesn't exist.
I can't find any reference to those strings on my machine. I've also searched the registry but can't find any reference in there either.
I can get into the Extensions manager if I click on one of the update notifications but the original error message just displays in the main pane and I can't do anything else. I can get to the online window but as soon as I click an extension, I am prompted with the original message.
I haven't installed any extensions or VS updates for a while but my Web Compiler extension extension has stopped auto compiling JSX files which is why I started trying to look at the Extension manager. I'm guessing the issues are related.
I can still work, compiling can be done manually which is inconvenient but not the end of the world. My worry is some other extensions are also misbehaving and I just haven't noticed yet.
Don't really want to re-install VS as a) it took ages last time and b) it might not fix the issue. Is there any good advice on troubleshooting the error or anything else I can try before I re-install?
I refreshed the GitHub extension on VS 2015 and got this error. Deleting the two cache files:
extensions.en-US.cache
extensionSdks.en-US.cache
from the AppData\Local\Microsoft\VisualStudio\14.0\Extensions causes them to be rebuilt and eliminates the error.
No reinstall needed.
Problem got worse, I started getting the error message when starting Visual Studio and things like the package manager wouldn't load. Each restart seemed to yield a different combination of windows not loading, sometimes Solution Explorer, sometimes Team Explorer etc. Not good.
A repair to VS 2015 via the Control Panel took a while but didn't help, same problems.
I ended up completely uninstalling and trying to re-install. However the installer threw an index was out of range error but weirdly VS 2015 was now listed as an installed application again.
So I'm guessing the original uninstall left some problematic files lying around which messed up the next install. So I uninstalled again, renamed Microsoft Visual Studio 14.0 folder, cleared all files from AppData\Local\Microsoft\VisualStudio\14.0\Extensions and re-installed.
It installed and ran fine.
The problem I now had was that I couldn't find the SQL Server Object Explorer window anywhere. I tried repairing SQL Server Data Tools but still no luck. So I uninstalled SSDT and then re-installed. This seemed to fix it.
Now I realised I also couldn't connect to Azure through the Server Explorer window, the option was simply not appearing in the list like it used to. This time a repair to Azure Tools for Microsoft Visual Studio 2015 - v2.9 and a repair to Azure App Service Tools v2.9 - Visual Studio 2015 fixed that problem.
I confronted same issue and found this thread. I tried the above suggestions, but unfortunately, it went all unsuccessful. I even tried to uninstall/install with even worse result as Visual Studio became unable to start due to new "missing components" issue. Reinstallation was nothing better.
I finally came by a piece of magic. It was Visual Studio Uninstaller which although would remove all your installed extensions, it would perform a complete cleanup. It would save you from installing new Windows (at least it was my case.
Just go to releases and download the first zip file
This way you will be able to perform clean install of Visual Studio.

Package Manager Console Error

When I start visual studio express 2012 for web I get this error in the package manager console.
Cannot load Windows PowerShell snap-in Microsoft.PowerShell.Core because of the following
error: Unable to load one or more of the requested types. Retrieve the LoaderExceptions
property for more information.
Loader Exceptions:
Exception of type 'System.OutOfMemoryException' was thrown.
I don't remember adding anything new to visual studio. I searched other related problems but they don't work for me.
I tried repairing visual studio. I also tried re-installing visual studio which temporarily removed the problem but it is back again.
Anyone has a solution?
I finally made it work. I suspected it is something from windows update that messed up with my VS since I didn't really add anything to VS. I am not sure which updates to remove so I just uninstalled all the windows update that starts in a certain date. Here are the actual steps that I did:
What I did is uninstalled visual studio 2012 express for web following this tutorial.
And then uninstalled windows updates starting from the date I believe the error started appearing.
After I used CCleaner to clean my registry. Had to run it 2 times to just to make sure it is clean. I'm not sure if this actually helps. I just heard from my friend that uninstalling applications sometime leaves registry keys behind.
Finally, I installed visual studio again. Package manager is back to normal.
Restarted my laptop and it is still working. So I guess it is solved.
I think System Restore would do solve this instead of doing all this steps. But system restore was not an option for .

Visual Studio crash at start-up

My Visual Studio began crashing at start-up. In my search for finding a remedy, I found these two suggestions, but neither worked for me:
Launching Visual Studio while running in safe mode, and
Running repair on Visual Studio.
However, I found that if I logged into a different Windows account, Visual Studio was able to run from that account without crashing.
Here is an error code that that I observed in the crash report:
LCID: 1033
Can anyone provide a solution for returning my Visual Studio to working order?
For me it turned out to be the plugin that GitExtensions installed into Visual Studio 2013.
-- UPDATE: try this before uninstalling GitExtensions
#Enceradeira proposed in the comments to uncheck the Show current branch in Visual Studio option. In GitExtensions, you get there via Tools -> Settings -> Appearance:
-- END OF UPDATE
After uninstalling GitExtensions and reinstalling it with all VS plugin unselected my VS runs smoothly again.
I even put together a blog post about this issue because it bugged me so much.
Since you're able to run with another user login, something may be wrong with your local settings, you can try to reset them: devenv /resetsettings in Start menu -> Run.
Warning: this will restore visual studio to default settings.
In my case VS used to crash on a single solution. I resolved the problem by deleting the respective solutions's user file: SolutionName.suo
My colleague recently experienced a problem with Visual Studio 2013 crashing on start-up. Unfortunately, we found that the approach recommended in the answer by #Arun M did not solve the problem:
devenv.exe /ResetSettings
...however, using a different command line argument did:
devenv.exe /ResetUserData
An easy way to run devenv.exe is via the Visual Studio command prompt; on Windows 10, it can be found here:
Start Button => All Apps => Visual Studio 2013 => Visual Studio Tools =>
VS2013 x86 Native Tools Command Prompt
For more about these command line arguments for devenv.exe, see this answer to this related question: How do I truly reset every setting in Visual Studio 2012?. ⚠ In particular, please note the cautionary statement in that answer about the /ResetUserData command line argument!
Try to run VS as administrator. That's necessary in my case.
If coincident to these Visual Studio crashes you are getting "Heap corruption" (Exception code: 0xc0000005) errors in your Windows Application log (Faulting module name: WindowsCodecs.dll), here is something worth checking into: A faulty WIC component within Expression Blend can cause ALL versions of Visual Studio to crash upon launch, as well as cause Internet Explorer to crash upon visiting many, if not most sites. Even though Microsoft distributes this component, they call it a "non-Microsoft component". As such, a Visual Studio reinstall won't fix this,, an OS reinstall over existing Windows installation won't fix this, and a system file integrity check won't detect it.
If my case, the misbehaving codec was "C:\Program Files (x86)\Microsoft Expression\Common\Imaging\4.0.360.0\PSDCodec.dll", and simply unregistering this component got my Visual Studio working again from consistent startup launch crashes.
I post this in hopes this solution to one source of Visual Studio crashing might save others from the $500 Microsoft support incident fee and week of downtime this caused me.
I just changed the windows language in the bottom right to "EN", then started as admin. And it worked, interesting..
I had the very strange phenomenon that both Visual Studio 2010 and 2013 on a Windows 7 machine crashed when run in a remote desktop session, started from a Windows 10 pc. Debugging the crash showed a CultureNotFound exception. It was caused by regional settings on the Windows 10 pc, which could not be translated in something understood by Windows 7. I had language English(Belgium) with an Azerty keyboard. I added and selected English(UK) with an Azerty keyboard and the crashes disappeared. No other programs suffered from this.
For me it was being caused by Web Essentials and I was able to resolve by disabling it, restarting VS, enabling it back , restart again. Works now.
I had a crash on startup (or soon after startup, before opening any solution) occurring in git2-msvstfs.dll, caused by placing a 3GB temp file into a directory within my solution. Deleting the file fixed it.
Once I accidentally pressed a random key combination (maybe something like ctrl+', but I didn’t realize I was holding ctrl down so I forgot what keys I hit by the time I realized something bad had happened) that resulted in VS Professional 2017 15.3.5 crashing within half a minute. After relaunching, I found that VS would be interactive for a few seconds before it would crash within half a minute. It was really too fast for me to try to figure out what I had accidentally activated or for me to disable it before VS would crash. Also, it would even crash if I didn’t open any solution, so I figured it was not something that deleting a .vs (per project/solution Solution Explorer/open files state) folder would fix.
To fix, I followed Arun M’s comment and renamed my %LOCALAPPDATA%\Microsoft\VisualStudio\15.0_3f4d04be folder. You will need to adjust the path for the edition/version of VS that is crashing. On my machine, I think 15.0_3f4d04be is Professional and 15.0_0fed6c59 is VS Community Edition. You’ll probably have to guess based on the folder’s modification timestamp which is probably going to reflect the date you last used that edition of VS.
After renaming the versioned dotfolder, VS launched without crashing. It started with default settings but automatically restored some of my settings through the cloud sync stuff after a minute of running and it even remembered my account information so I didn’t need to sign in.
I did not need to rename my %LOCALAPPDATA%\Microsoft\VSCommon folder (which Arun M had also suggested).
I had a similar problem, both VS2015 and VS2013 would crash at startup. Tracked it down to an application I installed which put .net 4.7.2 on the system. Once i removed that app, removed .net, and reinstalled .net 4.6, Visual Studio started working again.

Visual Studio 2010 crashes repeatedly

I've been running Visual Studio 2010 (the official release) for some time now. Lately, VS will crash 10+ times during my 8 hour work day. In VS2008, crashes were common when working with large Xaml files, and while I experience some of that with VS2010, crashes occur when debugging, starting the debugger, stopping the debugger, and other random times when editing code.
I've looked through the problem reports, and the one I've found that occurs most frequently is:
Description
Faulting Application Path: C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe
Problem signature
Problem Event Name: APPCRASH
Application Name: devenv.exe
Application Version: 10.0.30319.1
Application Timestamp: 4ba1fab3
Fault Module Name: ntdll.dll
Fault Module Version: 6.1.7600.16385
Fault Module Timestamp: 4a5bdb3b
Exception Code: c0000005
Exception Offset: 0002e23e
I'm running Windows 7 (x64). Hoepfully someone has come across this problem and has found a solution. I plan on reinstalling VS2010. Hopefully that takes care of the problem.
Do you think you have installed any extra Extensions which might lead to frequent crashes?
You can try
Devenv.exe /SafeMode
to start in Safe mode. You can also try
Devenv.exe /Log
Which will log all activity. Have not tried this so don't know What activities are logged.
Visual Studio 2010 Command Line Switches
I was having a similar problem and this helped me
http://connect.microsoft.com/VisualStudio/feedback/details/618802/visual-studio-random-frequent-crash
Running this from the command prompt seemed to fix it. It hasn't crashed for the whole day today.
regsvr32 c:\Windows\System32\ole32.dll
I had similar issues with Visual Studio. The problem was the service pack which for some reason was not installed properly.
I had to reapply the SP1 using the Repair / reapply option. This kind of fixed my issue.
Also make sure to reboot the system.
Just to help people who search it: It was webex instant messenger related part, but not Cisco itself. The cause was a component in Studio Power Tools relevant to integration with messenger. Reinstall power tools but without messaging integration.
In other occasion it is almost always a corporate antivirus authentication helper thing. It required to manually remove registry entries which cause background TFS logins break the studio at random moments.
I had the "Microsoft Visual Studio 2010 has stopped working" error, imediately when Visual Studio 2010 was starting. Fault module was clr.dll in my case. Only rebooting helped sometimes.
I solved it by removing .NET completely and reinstalling it.
Be aware that if you updated to .NET 4.5 this includes .NET 4, so you have to remove and reinstall .NET 4.5
I know why it could be crashing. Code it self. Have you tried to debug the failed instance of VS2010 with Vs2010? If the xaml designer crashed anywhere in your code you should be able to see the stack trace. Also, try to load the same xaml into Blend 4 and then run the vs2010 on Blend when that crashes. I've had some good results debugging Vs2010 crashes like that.
There are so many things that can cause studio to crash.
I'd look at everything from video card drivers to whether the RAM is stable.
Note, there is a microsoft connect but on this exact issue at: http://connect.microsoft.com/VisualStudio/feedback/details/634162/devenv-exe-frequent-intermittent-crashes-fault-module-name-ntdll-dll
You might vote on it or add your own information to the report but the very first thing I'd do is update my video drivers. One place I was at had a lot of issues with 2005; it would randomly crash just displaying the design surface or when opening a few too many code files; but once we got decent video cards and the appropriate drivers installed it worked flawlessly.
I disabled “Options"-"Evnironment"-"Add-in/Micros Security"->"Allow macros to run", and fixed the problem.
I think I just solved a similar issue on my computer, but probably not the same cause. It was related to TortoiseSVN (I think visual loads the tortoise DLL because it is integrated with the explorer, even if I don't have a specific visual studio plug-in). I upgraded TortoiseSVN (from 1.7.8 to 1.7.11) and it didn't crash for a few hours (I also had a 100% repro case when closing visual studio which does not happen anymore). Maybe there is some way to check what DLLs are loaded by visual studio to troubleshoot what are the candidates for upgrading/uninstalling, but I didn't go this far.
Hope it can help someone else.
While developing C++ code, Visual Studio 2010 started crashing frequently and at random times after I enabled the Task List.
As an alternative to using the Task List, I am now simply using the Find in Files tool (Ctrl+Shift+F) and searching for the string TODO as an alternative.
i was having a similar problem. visual studio 2010 was crashing. when i attached, it said it had a read access violation in ntdll.dll
closed all my open instances (there were 5) and it stopped happening.
Today I had this error, in my case it was because Microsoft released the update (KB2858725) the FrameWork 4.5.1, which the download and installed,
However this is definitely addressed by performing the following steps:
FrameWork 4.5.1 download (KB2858728) => NDP451-KB2858728-x86-x64-ENU.exe-Allos
http://www.microsoft.com/en-us/download/details.aspx?id=40779
Install the downloaded software (KB2858728)
Try Vs, but give the same error.
Uninstall the downloaded software (KB2858728)
(this task fully cleaned upgrade giving problems (KB2858725)
Install the downloaded software (KB2858728) again
Try Vs, this time if it will work
NOTE: NEVER! install update (KB2858725)
Logging helps indeed. I have the same problem with crashes. Since there could be numerous reasons and lots of log data, I wrote this .bat (Win7 x64, VS2010 Express) to keep logs organized and easy to analyze:
#echo off
rem date and time in format YYYYMonDD_hhmmss
set year=%DATE:~-4%
set month=%DATE:~3,2%
set day=%DATE:~0,2%
IF %month%==01 set monthstr=Jan
IF %month%==02 set monthstr=Feb
IF %month%==03 set monthstr=Mar
IF %month%==04 set monthstr=Apr
IF %month%==05 set monthstr=May
IF %month%==06 set monthstr=Jun
IF %month%==07 set monthstr=Jul
IF %month%==08 set monthstr=Aug
IF %month%==09 set monthstr=Sep
IF %month%==10 set monthstr=Oct
IF %month%==11 set monthstr=Nov
IF %month%==12 set monthstr=Dec
set now=%TIME:~0,-3%
set now=%now::=%
set now=%now: =0%
set now=%year%%monthstr%%day%_%now%
start "VS2010 express" "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\VCExpress.exe" /Log "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VSlogs\VS_log_%now%.txt"
I had the same problem. I cleared my settings. Configured environment to use C# development settings. Then i disabled all extensions against which disable button was present. I enabled them one by one while opening, running and closing solutions. I found the offending extension to be .Net reflector v 8.5.0.179 by red gate. I had VS2010, VS2012 and VS2013 all installed on my windows 8.1 enterprise 64bit. All of them had the same issue. Whenever i closed the solution VS would crash. Hope it helps.

Resources