How do I fix "InPageError" crash in Visual Studio 2010? - visual-studio-2010

I suddenly started getting an "InPageError" crash in VS last week. The error happens when attempting to open a solution or when trying to create a new project. It also happens when using msbuild from the command line.
I've tried everything that comes to mind to fix this, including numerous hours of research on the web. I applied quite a few updates from Windows Update last week, including updates for VS and for MS Office. I went through and removed all these, I uninstalled iTunes which I had just upgraded, and I uninstalled another application which I installed around the same time. I tried running VS in safe mode, and I tried resetting all VS settings to default. I ran chkdsk /f on my drive and it did find a few bad sectors and fixed them.
None of this seemed to help, so I decided to leave everything alone for a while (Friday to Sunday) and what do you know, suddenly VS came up without the crash yesterday, and worked flawless. After things started working yesterday I did reapply my VS settings, I reapplied Windows Updates, and I reinstalled the application I previously uninstalled. VS continued to work.
This morning, though, I'm getting the crash again, and I'm back to square one, not having any idea what the source of the problem is. So, anyone with a solution or insights?
Details:
"Microsoft Visual Studio has encountered a problem and needs to close."
Problem signature:
Problem Event Name: InPageError
Error Status Code: c00000b5
Faulting Media Type: 00000003
OS Version: 6.1.7601.2.1.0.256.48
Locale ID: 1033
I find two entries in the Windows Application Event Log:
Faulting application name: devenv.exe, version: 10.0.40219.1, time stamp: 0x4d5f2a73
Faulting module name: clr.dll, version: 4.0.30319.1008, time stamp: 0x517a1be7
Exception code: 0xc0000006
Fault offset: 0x00006680
Faulting process id: 0x130c
Faulting application start time: 0x01ceef89e76ac906
Faulting application path: C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe
Faulting module path: C:\Windows\Microsoft.NET\Framework\v4.0.30319\clr.dll
Report Id: 389154b1-5b7d-11e3-a7f8-f0def11d2248
Windows cannot access the file C:\Windows\assembly\NativeImages_v4.0.30319_32\Microsoft.Build\de24e9111354bdacab0e578fe8146d9a\Microsoft.Build.ni.dll for one of the following reasons: there is a problem with the network connection, the disk that the file is stored on, or the storage drivers installed on this computer; or the disk is missing. Windows closed the program Microsoft Visual Studio 2010 because of this error.
Program: Microsoft Visual Studio 2010
File: C:\Windows\assembly\NativeImages_v4.0.30319_32\Microsoft.Build\de24e9111354bdacab0e578fe8146d9a\Microsoft.Build.ni.dll
The error value is listed in the Additional Data section.
User Action
1. Open the file again. This situation might be a temporary problem that corrects itself when the program runs again.
2. If the file still cannot be accessed and
- It is on the network, your network administrator should verify that there is not a problem with the network and that the server can be contacted.
- It is on a removable disk, for example, a floppy disk or CD-ROM, verify that the disk is fully inserted into the computer.
3. Check and repair the file system by running CHKDSK. To run CHKDSK, click Start, click Run, type CMD, and then click OK. At the command prompt, type CHKDSK /F, and then press ENTER.
4. If the problem persists, restore the file from a backup copy.
5. Determine whether other files on the same disk can be opened. If not, the disk might be damaged. If it is a hard disk, contact your administrator or computer hardware vendor for further assistance.
Additional Data
Error value: C00000B5
Disk type: 3
I found some details about the errors:
0xC00000B5 STATUS_IO_TIMEOUT
{Device Timeout} The specified I/O operation on %hs was not completed before the time-out period expired.
0xC0000006 STATUS_IN_PAGE_ERROR
The instruction at 0x%08lx referenced memory at 0x%08lx. The required data was not placed into memory because of an I/O error status of 0x%08lx.

Related

Visual Studio CPU Profiler / No Data

Today my CPU Usage Performance profiler in Visual Studio stopped working. I start it, it seems like it's working, you can see the graph of the CPU going up and down but when it finishes I get no data with the message:
"There is no data in the current set of filters."
I have tried every combination of categories and filters with no luck. I restarted Visual Studio, I rebooted the workstation, I tried against a new hello world project. Other performance tools seem to work (e.g. the .NET Object Allocation Tracking tool works). To (try) to rule out that it was something specific in my project I was able to successfully run it on a 2nd workstation against the same set of code. I have also run VS without extensions and also in regular mode after disabling everything I've added in (like ReSharper).
Edit: Additionally I just found this in the Windows Event Viewer.
System.Runtime.InteropServices.COMException: The method or operation is not implemented., System.Object get_Value()
at EnvDTE.Property.get_Value()
at Microsoft.VisualStudio.PerformanceTools.ProjectTarget.LoadBinaryProject(IVsHierarchy hier)
at Microsoft.VisualStudio.PerformanceTools.ProjectTarget.LoadProjInfo()
This also just popped up in the Event Viewer under "Windows Error Reporting" that referenced a Watson VSTelem.Out error:
Fault bucket 125730739576, type 5
Event Name: PerfWatsonVS12Data
Response: Not available
Another oddity is, I just ran a profile session for maybe 20 seconds, however when it's done VS says "Diagnostic session: 127:47 minutes" which would be the about the time I first time I tried it this morning if it never stopped. I did a repair of Visual Studio from the installer and the profile worked for 1 session after, the 2nd session then reverted to the aforementioned behavior again.
I'm currently using:
Visual Studio 16.8.5 16.9.1 16.9.2 16.9.3 16.9.4 16.11.2
.NET Core SDK: 5.0.201
Windows 10 Version 2004 Build 19041.867
Any thoughts on fixes?
Edit: According to the following link, it might be related to a Windows Update and a bug in my NVidia driver:
https://developercommunity.visualstudio.com/t/no-data-in-cpu-usage-tool-windows-update-related/1384519
Microsoft confirmed the problem, as soon as a solution or workaround is found - report it. Follow the forum https://developercommunity.visualstudio.com/t/profiling-cpu-still-states-no-user-code-was-runnin/607535?from=email&viewtype=all#T-ND1373491

Does anyone have an issue with Visual Studio 2015 Data Tools crashing when running package?

I can build SSIS packages without any issues, but almost every time I run the package from Visual Studio it will crash. Sometimes it will crash within seconds of running the package, other times it will run a few minutes and then crash.
The only error being logged to the Windows event log is:
Faulting application name: devenv.exe, version: 14.0.25420.1, time stamp: 0x57685d85
Faulting module name: ucrtbase.dll, version: 10.0.17763.1, time stamp: 0xc3ae1887
Exception code: 0xc0000409
Fault offset: 0x000a5d0b
Faulting process id: 0x5bd4
Faulting application start time: 0x01d4cdf2158d4ebd
Faulting application path: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe
Faulting module path: C:\WINDOWS\System32\ucrtbase.dll
Report Id: 760baa61-e6fb-4646-83f5-94ed566b1d4a
Faulting package full name:
Faulting package-relative application ID:
I have tried repairing and reinstalling Visual Studio (multiple times), reinstalling Data Tools, and also reinstalling Visual C++ 2015 Redistributable (as I saw comments from others online with what I thought would be a similar ucrtbase.dll issue. This is a work computer, and others here have had the same issue in the past, but it seems to have been resolved for them after performing some of the steps I have already done. For a while we thought it was related to using the Balanced Data Distributor, but I have removed that altogether and am still having issues. Any help/ideas would be greatly appreciated.
Environment:
Window 10 version 1809
Visual Studio 2015 update 3
SQL Server Data Tools 2015
Kingswaysoft v10.2
This is not the best (or right) answer, but rather a workaround. As I cannot perform my job with a buggy VS, I decided to try VS 2017 (with SSDT 2017, etc.) As of the past couple hours that has been working and has not crashed on me (yet). My workaround for now, until we can fully move to 2017, will be to create new projects in 2015 so that other developers will continue to be able to work with me, but then switch over to 2017 for testing.
If anyone comes around with a real solution to the issue (my guess is it's some combination of VS, SSDT, Windows, and other updates), please share.

ScriptedSandbox64.exe has stopped working - Visual Studio 2015

This is the second time I've seen the error "Scripted Sandbox64.exe has stopped working" in Visual Studio 2015.
In my particular case, I was building a Windows Forms application and you place the application into the system tray in Windows. This application also writes files using System.IO. The project has nothing more than that. Visual Studio 2015 Community Edition crashes.
Disable the Diagnostic tool under
Tools -> Options -> Debugging -> General -> Enable Diagnostic Tools while debugging
More information: https://stackoverflow.com/a/31904957/2856307
Just adding the information that #Bahien Nguyen provided in his answer.
Reference:
http://www.expertdebugger.com/2016/01/19/how-to-fix-visual-studio-2015-error-faulting-application-name-scriptedsandbox64-exe-has-stopped-working/
How to fix Visual Studio 2015 error Faulting application name ScriptedSandbox64.exe has stopped working
I am trying to debug a windows application in Visual Studio 2015. I have already installed the latest updates. After the debugging starts, I get the following pop up error ScriptedSandbox64.exe has stopped working A problem caused program to stop working correctly.
The event viewer is showing the following details
Faulting application name: ScriptedSandbox64.exe, version: 14.0.24720.0, time stamp: 0x564e98d0
Faulting module name: ScriptedSandbox64.exe, version: 14.0.24720.0, time stamp: 0x564e98d0
Exception code: 0xc0000602
Fault offset: 0x000000000000f933
Faulting process id: 0x51c
Faulting application start time: 0x01d152888b333a1c
Faulting application path: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\PrivateAssemblies\ScriptedSandbox64.exe
Faulting module path: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\PrivateAssemblies\ScriptedSandbox64.exe
Report Id: 029bb0e0-771e-4046-bbc1-2c69686f144a
Faulting package full name:
Faulting package-relative application ID:
IDE gets locked up due to this and the only option is to click on close program.
Solution
This process is launched during debugging. Stop Visual Studio debugging session.
Disable the Diagnostic tool under Tools->Options->Debugging->General disable the option Enable Diagnostic Tools while debugging
Debugger still works after unchecking the above option.ScriptedSandbox64.exe no more throws any errors.
Dear Reader,
Please share your feedback about this article . This will enable me to improve this for the benefit of other readers.
Solution for now is to install Visual Studio 2013 Community Edition and retrofit the project by changing the *.csproj file XML.
For anybody who has this problem:
I experienced the same problem debugging a WPF application today in VS2015 Community Update 2. I am sure that I did not have this before but I dont know how it crept back in. As mentioned before, disabling the Diagnostic Tools solves the problem. Unfortunately, this is not an option for me. Luckily, installing the "Update for Microsoft Visual Studio 2015 Update 2 (KB3151378)" solved the problem for good. Link: https://msdn.microsoft.com/en-us/library/mt695655.aspx?f=255&MSPPError=-2147217396
I had a very similar issue, same dialog as OP posted, but then I encountered the same when running the application in debug mode. That helped me find what was causing this error in my application.
I traced it down to an iteration through DataGridViewRows, which would contain about 1800+ rows. My iteration was to set a checkbox value to true, but I ended up not needing to do that anyways. Once I removed this, the application would run okay.

Visual Studio 2015 crashes

Visual studio that won't be repaired...
Everytime I want to compile an app on vs 2015 - it crashes. Even if I want to compile the main function or write somthing to it, there appears a window, which says
Visual Studio 2015 has stopped working
It goes same on 2013 Express version.
I have a clue why it won't work: when I open Team Explorer, an error appears:
Page '3185ed96-1cbd-4381-a439-636973542e50' not found.
I tried everything I have found in the internet and trust me - nothing worked.
I also tried some command prompt commands:
devenv.exe/ debug
devenv.exe/ resetsettings
devenv.exe/ instalvstemplates
devenv.exe/ resetskippings
devenv.exe/ resetuserdata
devenv.exe/ setup
devenv.exe/ safemode
Debug mode gave me some info about the error:
An unhandled exception of type 'System.InvalidOperationException' occurred in mscorlib.dll
Additional information: The service 'Microsoft.Internal.VisualStudio.Shell.Interop.SVsUIThreadInvokerPrivate' must be installed for this feature to work. Ensure that this service is available. HRESULT = 0x80004002
An exception was encountered while constructing the content of this frame. This information is also logged in "C:\Users\admin\AppData\Roaming\Microsoft\VisualStudio\14.0\ActivityLog.xml".
Exception details:
System.ArgumentException: Parametr is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
at Microsoft.VisualStudio.Shell.Package.CreateToolWindow(Type toolWindowType, Int32 id, UInt32 flags)
at Microsoft.VisualStudio.Shell.Package.CreateToolWindow(Type toolWindowType, Int32 id, ProvideToolWindowAttribute tool)
at Microsoft.VisualStudio.Shell.Package.FindToolWindow(Type toolWindowType, Int32 id, Boolean create, ProvideToolWindowAttribute tool)
at Microsoft.VisualStudio.Shell.Package.CreateToolWindow(Guid& toolWindowType, Int32 id)
at Microsoft.VisualStudio.Shell.Package.Microsoft.VisualStudio.Shell.Interop.IVsToolWindowFactory.CreateToolWindow(Guid& toolWindowType, UInt32 id)
at Microsoft.VisualStudio.Platform.WindowManagement.WindowFrame.ConstructContent()
But still nothing I was able to find has worked.
I reinstalled VS and repaired it - still nothing.
Then I have downloaded some .dlls, microsoft visual c++ redistributable packages and used Ccleaner to clean registry.
I think it's a very strange error; if you could advise me on a fix please?
Uncheck [Tools->Options->Environment->Automatically adjust visual experience based on client performance]
Uncheck [Use hardware graphics acceleration if available]
You can leave [Enable rich client visual experience] checked
I was having a lot of problems anywhere from random crashes, to crashing my Intel Graphics display driver, I turned it off and I have had no problems, it actually runs better. Maybe it will work for you
I was facing the same issue for team explorer.
First of all close all instances of visual studio and then try:
devenv /resetuserdata
Run above command at the command prompt; typically something similar to "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE"
Possible fix for these type errors:
try to update device driver (Intel HD Graphics) or Run with graphic driver if u got switch based or vice versa.
main executable is located
C:\Program Files (x86)\Microsoft Visual Studio
14.0\Common7\IDE\devenv.exe
Also if you are getting these type error on installation exe you can fix it the same way
Visual Studio uses WPF:
From this link: "Windows Presentation Foundation (WPF) differs from prior application platforms on Windows in that it uses its own DirectX-based hardware-accelerated rendering pipeline, when available, to draw the contents of any WPF windows. Prior application platforms were typically much less dependent on display driver quality because the bulk of their rendering was done in software rather than hardware."
So, it may conflict with the display driver causing it to stop if you don't have latest display driver or the latest .NET framework. Though there might be other reasons.
There is also a registry settings(regedit) which might help:
You can add a new DWORD(for 32-bit systems) or QWORD(for 64-bit) by going to [HKEY_LOCAL_MACHINE->SYSTEM->CurrentControlSet->Control->GraphicsDrivers]
and setting the name to "TdrDelay" and value to "8". Make sure the value's base is set to hexadecimal. TDR- Timeout Detection and Recovery.
If any of the above doesn't work. Try disabling any hardware accelerated rendering features in Visual Studio from [Tools->Options]. From your ActivityLog file, it seems that the exceptions are mostly in the graphics methods. So, my guess is it has to do with graphics rendering.
Click on Tools menu > Import and Export Settings > Reset all settings > Next > "No, just reset settings, overwriting all current settings" > Next > Finish.
i have faced problem of visual studio installation
it stop before start installation and i just go to control panel > programs >Turn windows features on or of > just uncheck all the .NETframework versions and restart your machine and then start the installation
this just how it works with me
You can also try closing VS, deleting the bin directory then attempting to debug again – it has worked for me.
It's been a while, but I'm seeing similar behavior since today.
Every time I load our solution, VS2015 crashes and restarts.
Windows Event Log shows 'out of memory exception' but there's over 2GB free at the time of the crash. the faulting module is KERNELBASE.DLL
In case this helps anyone:
Faulting application name: devenv.exe, version: 14.0.25420.1, time stamp: 0x57685d85
Faulting module name: KERNELBASE.dll, version: 6.1.7601.23915, time stamp: 0x59b94abb
I'm suspecting a windows update, as none of my colleagues have this problem and unfortunately I'm that nerd who always installs his updates ASAP.
I found this SOF article and tried everything listed.
And I found a new caveat to this voodoo.
Mine falls under the "the dumbest reason ever" category.
My temp folder was "full". So I did a disk clean up, and that deleted the FILES. However, I had a large amount of subfolders in my temp folder and while they were empty, the folders themselves were causing GetTempFile functions to fail.
So when I ran
"C:\blah\blah\blah\IDE\devenv.exe" /log
the log entries in ActivityLog.xml were showing something like this:
System.IO.IOException: The file exists.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.__Error.WinIOError()
at System.IO.Path.InternalGetTempFileName(Boolean checkHost)
at System.Windows.Input.Cursor.LoadFromStream(Stream cursorStream)
at Microsoft.VisualStudio.Text.Editor.Implementation.LeftSelectionMargin.get_RightArrowCursor()
at Microsoft.VisualStudio.Text.Editor.Implementation.LeftSelectionMarginProvider.CreateMargin(IWpfTextViewHost textViewHost, IWpfTextViewMargin containerMargin)
at Microsoft.VisualStudio.Text.Utilities.ContainerMargin.<AddMargins>b__2(IWpfTextViewMarginProvider mp)
at Microsoft.VisualStudio.Text.Utilities.GuardedOperations.InstantiateExtension[TExtension,TMetadata,TExtensionInstance](Object errorSource, Lazy`2 provider, Func`2 getter)
In that log entry text, don't miss the text "System.IO.Path.InternalGetTempFileName"
So several places said "delete your temp files", which I did, but I still got the same issues. :(
Then I took a look at the temp directory, and I saw something weird. A large amount of (empty) subfolders.
So once I discovered I had a bunch of subfolders in my temp directory, I cleaned up these subfolders.
I found this question:
How to delete files/subfolders in a specific directory at command prompt in Windows
So I used this code:
I put this code in a .bat file
del /q "C:\Users\MYUSERNAME\AppData\Local\Temp\*"
FOR /D %%p IN ("C:\Users\MYUSERNAME\AppData\Local\Temp\*.*") DO rmdir "%%p" /s /q
And now my Visual Studio is running ok again.
Wow, go figure.
if you're using windows 10. Try installing VS2015 update 3
https://learn.microsoft.com/en-us/previous-versions/mt752379(v=vs.140)?redirectedfrom=MSDN

VSTest disk drive error whenever a test asserts

I have a native unit testing project in Visual Studio 2013 that has been testing the development of a C++ library for many months. Out of seemingly nowhere, Visual Studio has started popping the following message box whenever a test asserts:
vstest.executionengine.x86.exe - No Disk:
There is no disk in the drive. Please insert a disk into drive F:.
There are a few tests that access the filesystem, but I commented them out. I tried remaking the entire test project from scratch but it still is happening. Even a simple assert like this will cause the message box to appear:
Assert::IsTrue(false);
What is causing this behavior?
I'd try running VS setup in repair mode - maybe some of the vstest executables have disappeared and vs tries to find them on installer disk F
Definitely not an installation repair issue in my case. It just started to happen after I attached a new USB disk drive while tests were running.
Restarting the machine solved the problem.

Resources