Visual Studio 2013 crashes whenever I open a solution/project? - visual-studio-2013

Ever since I tried to open a VS2013 solution for a Unity 3D script project and got an "unsupported project type" error, I can't open any solutions without VS2013 crashing. I have VS2013 Ultimate. I can start the IDE without error. But the instant I try to load a solution it:
Crashes and tries to auto-restart
During the restart, crashes again and offers the "Debug/Close Program" option.
These are things I've tried so far to fix the error:
Rebooted my PC
Started with the /SAFEMODE flag
Started with administrator privileges
Deleted several SUO files
Nothing worked. I then went into the Uninstall Program module in the Control Panel. When I right-clicked on VS2013 there wasn't a Repair or Uninstall choice, only a Change choice. I clicked on that and oddly it went through the motions of doing the same activity as doing a version update. The operation took about an hour and had the familiar "Acquiring/Applying" dialog. After it was done there was a status update saying that the operation succeeded but that the Office Tools module could not be updated. I then restarted my system. I still have the crashing problem
Does anyone know how to fix this or what else to try
EXTRA DETAILS: I checked the system Event Viewer and did see a pair of Application Errors for DevEnv.exe for each failure. The is an Exception in KERNALBASE.dll:
Faulting application name: devenv.exe, version: 12.0.30723.0, time stamp: 0x53cf6f00
Faulting module name: KERNELBASE.dll, version: 6.3.9600.17415, time stamp: 0x54504ade
Exception code: 0xe0434352
Fault offset: 0x00014598
Faulting process id: 0x9cc
Faulting application start time: 0x01d02a6fbd23f686
Faulting application path: C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe
Faulting module path: C:\WINDOWS\SYSTEM32\KERNELBASE.dll
Report Id: ff3822e0-9662-11e4-bfb1-002618a93a45
Faulting package full name:
Faulting package-relative application ID:
The second is an Unhandled Exception from really odd place:
Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.ComponentModel.Win32Exception
Stack:
at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<ThrowAsync>b__3(System.Object)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)

I've deactivated Web Essentials for 2013 Update 4 (Under Extentensions & Updates), that makes VS load Web Projects again. I have no clue what happened since yesterday, as I did not install any updates.

Related

My installer program is crashing due to exception: 0xE0434352

I used Visual studio installshield to create an installation program and sent it to the server. When I tried to run the application on the server I get the following Microsoft windows message:
{” Myapplication has stopped working”
A problem caused the program to stop working correctly. Windows will close the program and notify you if a solution is available”}
When I click the Debug button.
I get the following exception:
[There is an unhandled win32 exception occurred in Myapplication.exe [6620]]
When I click debug using the selected debugger which is New instance of Visual Studio 2008
Microsoft visual studio threw the following exception:
[Unhandled exception at 0x76effd1e in Myapplication.exe: 0xE0434352: 0xe0434352]
Can someone help, please? I have no clue what any of this exception and error means.
I found the resource's to solving this exception here # stackoverflow, as suggested by #kynrek or rephrase by #kynrek,
By adding a handler for “AppDomain.CurrentDomain.UnhandledException as described here #
http://msdn.microsoft.com/en-us/library/system.appdomain.unhandledexception”
#kynrek should have credit for this answer.
Public Class Form1
Dim currentDomain As AppDomain = AppDomain.CurrentDomain
AddHandler currentDomain.UnhandledException, AddressOf MyHandler
Try
Catch ex As Exception
ErrMsgTextBox1.Text = (ex.Message)
End Try
Private Sub MyHandler(sender As Object, args As UnhandledExceptionEventArgs)
Dim e As Exception = DirectCast(args.ExceptionObject, Exception)
ErrMsgTextBox1.Text = (e.Message)
End Sub 'MyUnhandledExceptionEventHandler
End Class

I'm loading a .DLL in runtime, but always i stop the solution in debug mode and start again the program will crash

I'm using a device in my vb6 program and i loaded the .dll of this device during runtime in a module.
I need to declare all the methods of the .dll
Example:
Declare Function FTRGetParam Lib "FtrAPI.DLL" _
(ByVal Param As Long, ByRef value As Any) As Integer
But when i enter in this module again in the next execution, the program will crash and i must to close the Visual Studio IDE.
Any Idea?

VB6 Compile Outlook add-in - Compile Error: Automation Type Not supported in Visual basic

I have got an infuriating problem trying to compile a VB6 Outlook Add-in component following an upgrade of Office on the same PC to Office 2013 Pro Plus.
The error
Compile Error: Automation type not supported in Visual Basic
is being thrown on the line:
Implements IDExtensibility2
I will paste the full code from that file below.
On another PC, I managed to get everything set up, and upgrade Office to 2012 and it compiled no problem, but on that same PC now - I get the same error. I have messed around a lot with the Office install in the interim so I couldn't accurately tell you what I did in between it working and not working, but the bottom line is it seems it shouldn't be beyond possibility to do what I am trying to do (as I have done it!), I just need some guidance on what I may need to do to get back to a working setup. Any ideas??
Implements IDTExtensibility2
Private gBaseClass As New clsOlkAddIn
Private Sub IDTExtensibility2_OnAddInsUpdate(custom() As Variant)
'To Be Declared for IDTExtensibility2
End Sub
Private Sub IDTExtensibility2_OnBeginShutdown(custom() As Variant)
'To Be Declared for IDTExtensibility2
End Sub
Private Sub IDTExtensibility2_OnConnection(ByVal Application As Object, _
ByVal ConnectMode As AddInDesignerObjects.ext_ConnectMode, _
ByVal AddInInst As Object, custom() As Variant)
gBaseClass.InitHandler Application, AddInInst.ProgId
End Sub
Private Sub IDTExtensibility2_OnDisconnection(ByVal RemoveMode _
As AddInDesignerObjects.ext_DisconnectMode, custom() As Variant)
Dim objCB As Office.CommandBar
On Error Resume Next
'If RemoveMode = ext_dm_UserClosed Then
Set objCB = golApp.ActiveExplorer.CommandBars("Addin")
objCB.FindControl(Type:=msoControlPopup, Tag:="Menu").Delete
objCB.FindControl(Type:=msoControlButton, Tag:="AddEmailsButton").Delete
objCB.FindControl(Type:=msoControlButton, Tag:="SyncContactsButton").Delete
objCB.FindControl(Type:=msoControlButton, Tag:="SyncTasksButton").Delete
objCB.FindControl(Type:=msoControlButton, Tag:="SyncCalendarButton").Delete
objCB.Delete
'End If
gBaseClass.UnInitHandler
Set gBaseClass = Nothing
End Sub
Private Sub IDTExtensibility2_OnStartupComplete(custom() As Variant)
'To Be Declared for IDTExtensibility2
End Sub
Another cause of this error, as I found today is having an optional parameter on a function and giving it a default, e.g.
Public Function Foo(MyString as String, Optional MyVariant as variant = null)
Changing this to:
Public Function Foo(MyString as String, Optional MyVariant as variant)
Solved it, I didn't get there as simply as it looks above though (hence, why I'm hanging around here), I did change the optional parameter to a string first, which worked, in fact, even with a variant parameter, having a default of anything other than Null worked. It was the default of Null that was causing the error.
As you've confirmed in your answer (in comments), ensuring you've upgraded to the latest service pack is always the best option unless you know you're relying upon features that were dropped or changed in later service packs.
Installing the "Cumulative update rollup for the Visual Basic 6.0 Service Pack 6 Runtime Extended Files" (https://support.microsoft.com/en-us/help/957924/description-of-the-cumulative-update-rollup-for-the-visual-basic-6-0-s) resolved this error in my instance.

Visual Studio 2008 BuildEvent Macros not Firing

I added this well documented macro to MyMacros, Environment Events in VS 2008 Macros in order to cancel failed builds:
Private Sub BuildEvents_OnBuildProjConfigDone(ByVal Project As String, ByVal ProjectConfig As String, ByVal Platform As String, ByVal SolutionConfig As String, ByVal Success As Boolean) Handles BuildEvents.OnBuildProjConfigDone
If Success = False Then
'The build failed...cancel any further builds.
DTE.ExecuteCommand("Build.Cancel")
End If
But it's not canceling my builds. I also set breakpoints to hopefully catch it firing but they are not hit either.
I also added this test macro but its not being fired either:
Private Sub BuildEvents_OnBuildBegin(ByVal Scope As EnvDTE.vsBuildScope, ByVal Action As EnvDTE.vsBuildAction) Handles BuildEvents.OnBuildBegin
Beep()
Beep()
End Sub
The "Allow macros to run" option is set.
Why is it not being fired? Why are my breakponts not being hit?
Thanks for your help
Apparently you have to run Debug (green play button) in the Macros IDE for breakpoints to be hit.
Now I know.

Why have my Visual Studio 2008 SP1 macros stropped working

I just cannot for the life of me figure out why my build event macro is no longer firing. Any ideas?
Option Strict Off
Option Explicit Off
Imports System
Imports EnvDTE
Imports EnvDTE80
Imports EnvDTE90
Imports System.Diagnostics
Public Module EnvironmentEvents
Private Sub BuildEvents_OnBuildProjConfigDone(ByVal Project As String, _
ByVal ProjectConfig As String, _
ByVal Platform As String, _
ByVal SolutionConfig As String, _
ByVal Success As Boolean) _
Handles BuildEvents.OnBuildProjConfigDone
If Success = False Then
'The build failed...cancel any further builds.
DTE.ExecuteCommand("Build.Cancel")
End If
End Sub
End Module
Have you tried running Windows Update? Are all the macros not working or just this one?

Resources