Specifications
Visual Studio 2015 SP 1
.NET 4.0
VB.NET
I'm having a weird issue where my program doesn't stop the process and highlight the error point with the convenient popup that I'm used to. Instead the program dumps the error into the Output and I have to look through it to find where the issue is, what it is, and what it was.
This is getting kind of annoying and I wonder if this is a setup issue. My move to VS2015 was recent and I remade the project files so they would be a pure VS2015 project. The debugger was working at first, but it stopped a few days ago. This is the average message I get;
The thread 0x2044 has exited with code 0 (0x0).
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'D:\Programming\ProgramName-Download\ProgramName\bin\Debug\ProgramName.exe'. Symbols loaded.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'C:\WINDOWS\Microsoft.Net\assembly\GAC_MSIL\System.Runtime.Remoting\v4.0_4.0.0.0__b77a5c561934e089\System.Runtime.Remoting.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'C:\WINDOWS\Microsoft.Net\assembly\GAC_MSIL\System.Configuration\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Configuration.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'C:\WINDOWS\Microsoft.Net\assembly\GAC_64\System.Transactions\v4.0_4.0.0.0__b77a5c561934e089\System.Transactions.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'C:\WINDOWS\Microsoft.Net\assembly\GAC_64\System.EnterpriseServices\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.EnterpriseServices.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'C:\WINDOWS\Microsoft.Net\assembly\GAC_64\System.EnterpriseServices\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.EnterpriseServices.Wrapper.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'C:\WINDOWS\Microsoft.Net\assembly\GAC_MSIL\System.Numerics\v4.0_4.0.0.0__b77a5c561934e089\System.Numerics.dll'. Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
'ProgramName.vshost.exe' (CLR v4.0.30319: ProgramName.vshost.exe): Loaded 'D:\Programming\ProgramName-Download\ProgramName\bin\Debug\ToolBoxCS.dll'. Symbols loaded.
The thread 0x213c has exited with code 0 (0x0).
Exception thrown: 'System.InvalidCastException' in ProgramName.exe
System.Transactions Critical: 0 : <TraceRecord xmlns="http://schemas.microsoft.com/2004/10/E2ETraceEvent/TraceRecord" Severity="Critical"><TraceIdentifier>http://msdn.microsoft.com/TraceCodes/System/ActivityTracing/2004/07/Reliability/Exception/Unhandled</TraceIdentifier><Description>Unhandled exception</Description><AppDomain>ProgramName.vshost.exe</AppDomain><Exception><ExceptionType>System.InvalidCastException, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</ExceptionType><Message>Specified cast is not valid.</Message><StackTrace> at ProgramName.Interview.Load_Interview(Int32 Control, String Clientcode) in D:\Programming\ProgramName-Download\ProgramName\Class\Interview.vb:line 493
at ProgramName.frmInterview.frmInterview_Load(Object sender, EventArgs e) in D:\Programming\ProgramName-Download\ProgramName\Applications\frmInterview.vb:line 97
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)</StackTrace><ExceptionString>System.InvalidCastException: Specified cast is not valid.
at ProgramName.Interview.Load_Interview(Int32 Control, String Clientcode) in D:\Programming\ProgramName-Download\ProgramName\Class\Interview.vb:line 493
at ProgramName.frmInterview.frmInterview_Load(Object sender, EventArgs e) in D:\Programming\ProgramName-Download\ProgramName\Applications\frmInterview.vb:line 97
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)</ExceptionString></Exception></TraceRecord>
The program '[7424] ProgramName.vshost.exe' has exited with code -1073741819 (0xc0000005) 'Access violation'.
The weird part is the code window goes to where the problem is, but the debug stops at the same time without a popup.
So did I accidentally check off some option I really needed or do something stupid that is easy to fix. Is this an issue with my code or maybe a permission setting?
Edit:
Debug mode is on:
Related
I get Visual Studio crashing everytime I add a Nuget Reference. It feels like a BUG.
It was reported to the Developer Community (beta) site: https://developercommunity.visualstudio.com/content/problem/6782/manage-nuget-packages-crashes-vs2017rc.html
It states it was fixed, so the exact root cause of this must be different:
The problem looks like it existed back in 2015 but no answers: Nuget Package Manager crashes when clicking "Manage nuget packages for solution" Visual Studio 2015
Its so annoying I have to use the Console to install packages or edit the packages.config file manually and then restore the packages. Not Happy - does anyone have a solution?
Specs
Win7 x64
Microsoft Visual Studio Enterprise 2017
Version 15.2 (26430.6) Release
VisualStudio.15.Release/15.2.0+26430.6
Microsoft .NET Framework v 4.7.02053
Installed Version: Enterprise
.....
NuGet Package Manager 4.2.0
Event Log:
Application: devenv.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.UnauthorizedAccessException
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
at Microsoft.VisualStudio.Shell.Settings.ShellWritableSettingsStore.CreateCollection(String collectionPath)
at Microsoft.VisualStudio.PlatformUI.CategoryMRUItems.SaveItems(WritableSettingsStore store)
at Microsoft.VisualStudio.PlatformUI.MRUItemsStoreService.AddMRUItem(Guid& guidCategory, String lpszItem)
at Microsoft.VisualStudio.PlatformUI.MruItemsStoreServiceDecorator.AddMRUItem(Guid& guidCategory, String lpszItem)
at Microsoft.VisualStudio.Platform.WindowManagement.WindowSearchHost.Microsoft.VisualStudio.Platform.WindowManagement.IWindowSearchEventsHandler.OnAddMRUItem(String searchedText)
at Microsoft.VisualStudio.Platform.WindowManagement.WindowSearchDataSource.OnAddMRUItem(String searchedText)
at Microsoft.VisualStudio.PlatformUI.SearchControlDataSource.AddMRUItemAction(GelDependencyObject datasource, Object parameter)
at Microsoft.Internal.VisualStudio.PlatformUI.GelDependencyObject.Invoke(GelVerb descriptor, Object param)
at Microsoft.Internal.VisualStudio.PlatformUI.GelDependencyObject.Invoke(String verb, Object param)
at Microsoft.Internal.VisualStudio.PlatformUI.GelDependencyObject.Invoke(String verb, Object pvaIn, Object& pvaOut)
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32, IntPtr)
at Microsoft.Internal.VisualStudio.PlatformUI.Utilities.Invoke(Microsoft.VisualStudio.Shell.Interop.IVsUIDataSource, System.String, System.Object)
at Microsoft.VisualStudio.PlatformUI.SearchControl.AddToMRUItems(System.String)
at Microsoft.VisualStudio.PlatformUI.SearchControl.SearchBox_LostKeyboardFocus(System.Object, System.Windows.Input.KeyboardFocusChangedEventArgs)
at System.Windows.Input.KeyboardFocusChangedEventArgs.InvokeEventHandler(System.Delegate, System.Object)
at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
at System.Windows.UIElement.RaiseEventImpl(System.Windows.DependencyObject, System.Windows.RoutedEventArgs)
at System.Windows.UIElement.RaiseTrustedEvent(System.Windows.RoutedEventArgs)
at System.Windows.UIElement.RaiseEvent(System.Windows.RoutedEventArgs, Boolean)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(System.Windows.Input.InputEventArgs)
at System.Windows.Input.KeyboardDevice.ChangeFocus(System.Windows.DependencyObject, Int32)
at System.Windows.Input.KeyboardDevice.TryChangeFocus(System.Windows.DependencyObject, System.Windows.Input.IKeyboardInputProvider, Boolean, Boolean, Boolean)
at System.Windows.Input.KeyboardDevice.Focus(System.Windows.DependencyObject, Boolean, Boolean, Boolean)
at System.Windows.Input.KeyboardDevice.Focus(System.Windows.IInputElement)
at System.Windows.UIElement.Focus()
at System.Windows.Controls.ListBoxItem.HandleMouseButtonDown(System.Windows.Input.MouseButton)
at System.Windows.Controls.ListBoxItem.OnMouseLeftButtonDown(System.Windows.Input.MouseButtonEventArgs)
at System.Windows.UIElement.OnMouseLeftButtonDownThunk(System.Object, System.Windows.Input.MouseButtonEventArgs)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(System.Delegate, System.Object)
at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
at System.Windows.UIElement.ReRaiseEventAs(System.Windows.DependencyObject, System.Windows.RoutedEventArgs, System.Windows.RoutedEvent)
at System.Windows.UIElement.OnMouseDownThunk(System.Object, System.Windows.Input.MouseButtonEventArgs)
at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(System.Delegate, System.Object)
at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
at System.Windows.UIElement.RaiseEventImpl(System.Windows.DependencyObject, System.Windows.RoutedEventArgs)
at System.Windows.ContentElement.RaiseTrustedEvent(System.Windows.RoutedEventArgs)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.InputManager.ProcessInput(System.Windows.Input.InputEventArgs)
at System.Windows.Input.InputProviderSite.ReportInput(System.Windows.Input.InputReport)
at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr, System.Windows.Input.InputMode, Int32, System.Windows.Input.RawMouseActions, Int32, Int32, Int32)
at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr, MS.Internal.Interop.WindowMessage, IntPtr, IntPtr, Boolean ByRef)
at System.Windows.Interop.HwndSource.InputFilterMessage(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 System.Windows.Threading.ExceptionWrapper.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)
Faulting application name: devenv.exe, version: 15.0.26430.6, time stamp: 0x5914d7fe
Faulting module name: KERNELBASE.dll, version: 6.1.7601.23807, time stamp: 0x5915f98e
Exception code: 0xe0434352
Fault offset: 0x0000c54f
Faulting process id: 0xf48
Faulting application start time: 0x01d2fb77b5f33dcc
Faulting application path: C:\Program Files x86\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\devenv.exe
Faulting module path: C:\WINDOWS\syswow64\KERNELBASE.dll
Report Id: f949036c-676b-11e7-8422-3417ebddc764
Error Handler Exception: System.ServiceModel.CommunicationException: There was an error reading from the pipe: Unrecognized error 109 (0x6d). ---> System.IO.IOException: The read operation failed, see inner exception. ---> System.ServiceModel.CommunicationException: There was an error reading from the pipe: Unrecognized error 109 (0x6d). ---> System.IO.PipeException: There was an error reading from the pipe: Unrecognized error 109 (0x6d).
at System.ServiceModel.Channels.PipeConnection.OnAsyncReadComplete(Boolean haveResult, Int32 error, Int32 numBytes)
--- End of inner exception stack trace ---
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Channels.ConnectionStream.EndRead(IAsyncResult asyncResult)
at System.Net.FixedSizeReader.ReadCallback(IAsyncResult transportResult)
--- End of inner exception stack trace ---
at System.Net.Security.NegotiateStream.EndRead(IAsyncResult asyncResult)
at System.ServiceModel.Channels.StreamConnection.EndRead()
--- End of inner exception stack trace ---
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Channels.TransportDuplexSessionChannel.EndTryReceive(IAsyncResult result, Message& message)
at System.ServiceModel.Dispatcher.DuplexChannelBinder.EndTryReceive(IAsyncResult result, RequestContext& requestContext)
at System.ServiceModel.Dispatcher.ErrorHandlingReceiver.EndTryReceive(IAsyncResult result, RequestContext& requestContext) \r\n at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Channels.TransportDuplexSessionChannel.EndTryReceive(IAsyncResult result, Message& message)
at System.ServiceModel.Dispatcher.DuplexChannelBinder.EndTryReceive(IAsyncResult result, RequestContext& requestContext)
at System.ServiceModel.Dispatcher.ErrorHandlingReceiver.EndTryReceive(IAsyncResult result, RequestContext& requestContext)
I used SysInternals Process Monitor to find out that actual ACCESS_DENIED happens when VS attempts to RegCreateKey for a key:
\REGISTRY\A\{4B5F9AD2-BB8B-4CF8-9ACB-201C56F4D086}\Software\Microsoft\VisualStudio\15.0_05fc10d7\MRUItems\{00000000-0000-0000-0000-000000000000}\Items
This key appears to be stored in VS application hive file:
C:\Users\<user name>\AppData\Local\Microsoft\VisualStudio\15.0_05fc10d7\privateregistry.user.bin
I started regedit as admin, loaded hive file into regedit as described:
Launch RegEdit.exe
Select the Computer\HKEY_LOCAL_MACHINE node in the left-hand pane
Select the File | Load Hive... menu item, and load the privateregistry.user.bin
When prompted for a key name, just type in something like "VSRegHive"
This will load the data into a VSRegHive under the HKLM node
Create the 2 absent keys {00000000-0000-0000-0000-000000000000}\Items:
When finished select the VSRegHive and select
File | Unload Hive... , before exiting the RegEdit.exe utility, otherwise
VS will fail to start. Keeping the hive loaded in regedit creates some
sort of lock that prevents DevEnv.exe from launching.
With the 2 missing keys in place VS2017 doesn't crash in NuGet manager.
My VS2017 also crashes in NuGet package manager so I'm unable to add packages to project. Try start VS2017 as Administrator, mine lets me add packages this way, then I restart VS2017 as a normal user.
I have a VB.net application that uses a custom serializable class to persist configuration settings. At startup, I deserialize the config file. This works perfectly in the debugger. I run the application in Visual Studio, it calls the LoadSettings function, and it instantiates the object. However, once I build the executable and run it, it generates an exception. Does anyone know why it is behaving differently between the debugger and compiled code?
The way the config file was created, was by serializing an object of class Settings, and writing that to a file using a StreamReader object. Pretty straightforward, I do it all the time.
Here's the subroutine:
Private Sub LoadSettings(FromFile As String)
Dim ser As New XmlSerializer(GetType(UtilityClasses.Settings))
Dim reader As New StreamReader(FromFile)
Settings = ser.Deserialize(reader)
reader.Close()
End Sub
And, on the ser.Deserialize() call, it raises this exception:
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
System.Configuration.ConfigurationErrorsException: Configuration system failed to initialize ---> System.Configuration.ConfigurationErrorsException: Configuration file MyUtility.config does not have root <configuration> tag (C:\Data\Code\MyUtility\bin\Debug\MyUtility.config line 2)
at System.Configuration.ConfigurationSchemaErrors.ThrowIfErrors(Boolean ignoreLocal)
at System.Configuration.BaseConfigurationRecord.ThrowIfParseErrors(ConfigurationSchemaErrors schemaErrors)
at System.Configuration.BaseConfigurationRecord.ThrowIfInitErrors()
at System.Configuration.ClientConfigurationSystem.EnsureInit(String configKey)
--- End of inner exception stack trace ---
at System.Configuration.ConfigurationManager.PrepareConfigSystem()
at System.Configuration.ConfigurationManager.GetSection(String sectionName)
at System.Configuration.PrivilegedConfigurationManager.GetSection(String sectionName)
at System.Diagnostics.DiagnosticsConfiguration.GetConfigSection()
at System.Diagnostics.DiagnosticsConfiguration.Initialize()
at System.Diagnostics.DiagnosticsConfiguration.get_SwitchSettings()
at System.Diagnostics.Switch.InitializeConfigSettings()
at System.Diagnostics.Switch.InitializeWithStatus()
at System.Diagnostics.Switch.get_SwitchSetting()
at System.Diagnostics.BooleanSwitch.get_Enabled()
at System.Xml.Serialization.TempAssembly.LoadGeneratedAssembly(Type type, String defaultNamespace, XmlSerializerImplementation& contract)
at System.Xml.Serialization.XmlSerializer..ctor(Type type, String defaultNamespace)
at System.Xml.Serialization.XmlSerializer..ctor(Type type)
at CATPrd2Prt.Form1.LoadSettings(String FromFile) in C:\Data\Code\MyUtility\Form1.vb:line 99
at CATPrd2Prt.Form1.Form1_Load(Object sender, EventArgs e) in C:\Data\Code\MyUtility\Form1.vb:line 30
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3662 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
CATPrd2Prt
Assembly Version: 1.0.0.0
Win32 Version: 1.0.0.0
CodeBase: file:///C:/Data/Clients/Inalfa/Code/CATPrd2Prt/CATPrd2Prt/bin/Debug/CATPrd2Prt.exe
----------------------------------------
Microsoft.VisualBasic
Assembly Version: 8.0.0.0
Win32 Version: 8.0.50727.3053 (netfxsp.050727-3000)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.VisualBasic/8.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualBasic.dll
----------------------------------------
System
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3662 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Windows.Forms
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3667 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3667 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
System.Configuration
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3654 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Xml
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3662 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
System.Runtime.Remoting
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.3664 (GDR.050727-3600)
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Runtime.Remoting/2.0.0.0__b77a5c561934e089/System.Runtime.Remoting.dll
----------------------------------------
Interop.INFITF
Assembly Version: 0.0.0.0
Win32 Version: 0.0.0.0
CodeBase: file:///C:/Data/Clients/Inalfa/Code/CATPrd2Prt/CATPrd2Prt/bin/Debug/Interop.INFITF.DLL
----------------------------------------
System.Core
Assembly Version: 3.5.0.0
Win32 Version: 3.5.30729.1 built by: SP
CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Core/3.5.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.
For example:
<configuration>
<system.windows.forms jitDebugging="true" />
</configuration>
When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.
Aha, figured it out. Apparently, naming the config file "MyUtility.config" was causing some kind of problem with the deserializer. But I have no idea why it was different during Debugging. I changed the name to "MyUtility.config.xml" and it worked fine.
I have a problem:
I have added the shockwave com object into my vb.net project and it works fine.
My development machine is a 64bit Windows 7
However on a test machine which is also windows 7 and has shockwave installed, I get the following error:
************** Exception Text **************
System.InvalidOperationException: An error occurred creating the form.
See Exception.InnerException for details.
The error is: Could not load file or assembly 'AxInterop.ShockwaveFlashObjects, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified. ---> System.IO.FileNotFoundException: Could not load file or assembly 'AxInterop.ShockwaveFlashObjects, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
The system cannot find the file specified.
at SENpic.Video_Player.InitializeComponent()
at SENpic.Video_Player..ctor()
--- End of inner exception stack trace ---
at SENpic.My.MyProject.MyForms.Create__Instance__[T](T Instance)
at SENpic.My.MyProject.MyForms.get_Video_Player()
at SENpic.frmStart.SensorySensitivityNationalAutisticSocietyToolStripMenuItem_Click(Object sender, EventArgs e)
at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
As far as I can see it should just work, any ideas?
Regards
Graham
I've sorted it. I hadn't noticed that in my build area two DDL files appeared:
AxInterop.ShockwaveFlashObjects.dll
Interop.ShockwaveFlashObjects.dll
I copied these into the folder with my EXE and the programme now played the files.
I am trying to debug an ASP.Net application in Monodevelop on Mac OS.
The application was debugging fine however now Monodevelop will not run it. When I right click the application and click on "Debug Item" it tries to build and start debugging but then nothing happens. In the bottom left corner it says "Build successful.".
If I right click the application and select "Run Item" in the bottom left of Monodevelop it says:
Execution failed. Object reference not set to an instance of an object.
How can I fix Monodevelop/ my application to debug properly?
I am using the latest versions on Mono and Monodevelop.
Here is the error that appears in the Monodevelop log when trying to debug.
Exception:
Error - 11:36:32 p.m. - Execution failed
System.NullReferenceException: Object reference not set to an instance of an object
at MonoDevelop.Projects.CustomCommand.ParseCommand (MonoDevelop.Core.StringParsing.StringTagModel tagSource, System.String& cmd, System.String& args) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/CustomCommand.cs:150
at MonoDevelop.Projects.CustomCommand.CreateExecutionCommand (IWorkspaceObject entry, MonoDevelop.Projects.ConfigurationSelector configuration) [0x00009] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/CustomCommand.cs:179
at MonoDevelop.Projects.CustomCommand.Execute (IProgressMonitor monitor, IWorkspaceObject entry, MonoDevelop.Projects.ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/CustomCommand.cs:230
at MonoDevelop.Projects.CustomCommandCollection.ExecuteCommand (IProgressMonitor monitor, IWorkspaceObject entry, CustomCommandType type, MonoDevelop.Projects.ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration) [0x00020] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/CustomCommandCollection.cs:60
at MonoDevelop.Projects.CustomCommandExtension.Execute (IProgressMonitor monitor, MonoDevelop.Projects.SolutionEntityItem entry, MonoDevelop.Projects.ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration) [0x00025] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/CustomCommandExtension.cs:75
at MonoDevelop.Projects.ProjectServiceExtension.Execute (IProgressMonitor monitor, IBuildTarget item, MonoDevelop.Projects.ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration) [0x0000b] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/ProjectServiceExtension.cs:179
at MonoDevelop.Projects.SolutionItem.Execute (IProgressMonitor monitor, MonoDevelop.Projects.ExecutionContext context, MonoDevelop.Projects.ConfigurationSelector configuration) [0x00000] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects/SolutionItem.cs:609
at MonoDevelop.Ide.ProjectOperations.ExecuteSolutionItemAsync (IProgressMonitor monitor, IBuildTarget entry, MonoDevelop.Projects.ExecutionContext context) [0x00006] in /Users/builder/data/lanes/monodevelop-mac-2.8.6.4/ca00645c/source/monodevelop/main/src/core/MonoDevelop.Ide/MonoDevelop.Ide/ProjectOperations.cs:917
Command:
Info - 11:40:14 p.m. - /Library/Frameworks/Mono.framework/Versions/2.10.8/bin/dmcs "/out:/Users/liam/Projects/techcertain/techcertaincsharp/bin/Migration.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Web.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Xml.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Web.Services.dll"
"/r:/Users/liam/Projects/techcertain/techcertaincsharp/bin/Npgsql.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Data.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Data.Linq.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Data.DataSetExtensions.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/Microsoft.VisualBasic.dll"
"/r:/Users/liam/Projects/techcertain/techcertaincsharp/bin/TCShared.dll"
"/r:/Users/liam/Projects/techcertain/techcertaincsharp/bin/TCLDAP.dll"
"/r:/Library/Frameworks/Mono.framework/Versions/2.10.8/lib/mono/4.0/System.Core.dll"
/nologo
/warn:4
/debug:+
/debug:full
/optimize-
/codepage:utf8
"/define:DEBUG"
/t:library
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/Default.aspx.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/Default.aspx.designer.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TC_Migrator.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TCMappable.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TCUserMigrator.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TCSchemeMigrator.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TCUserPermissionsMigrator.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TCFileMigrator.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/TCBaseClass.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/QueryTester.aspx.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/QueryTester.aspx.designer.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/MigEvents.aspx.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/MigEvents.aspx.designer.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/SysEvents.aspx.cs"
"/Users/liam/Projects/techcertain/techcertaincsharp/Migration/SysEvents.aspx.designer.cs"
I am getting the below error when i call "NServiceBus.Host.exe". The issue appears to be itextsharp.dll. I've read that i can use
"Configure.With(AllAssemblies.Except("itextsharp.dll"))... // rest of your config"
But i'm using the following sample and not sure where to add this property.
http://docs.particular.net/samples/web/asp-mvc-application/
#
Unhandled Exception: Magnum.StateMachine.StateMachineException: Exception occurr
ed in Topshelf.Internal.ServiceController1[[NServiceBus.Host.Internal.GenericHo
st, NServiceBus.Host, Version=2.6.0.1504, Culture=neutral, PublicKeyToken=9fc386
479f8a226c]] during state Initial while handling OnStart ---> System.Exception:
Exception when starting endpoint, error has been logged. Reason: Could not load
file or assembly 'file:///D:\dev\MYSITE\MYSITE.EStore\EStore.Server\bin\Debug\itexts
harp.dll' or one of its dependencies. Operation is not supported. (Exception fro
m HRESULT: 0x80131515)
at NServiceBus.Host.Internal.GenericHost.Start() in d:\BuildAgent-02\work\20b
5f701adefe8f8\src\host\NServiceBus.Host\Internal\GenericHost.cs:line 90
at Magnum.StateMachine.EventActionList1.Execute(T stateMachine, Event event,
Object parameter) in :line 0
--- End of inner exception stack trace ---
Server stack trace:
at Magnum.StateMachine.ExceptionActionDictionary1.HandleException(T stateMac
hine, Event event, Object parameter, Exception exception) in :line 0
at Magnum.StateMachine.EventActionList1.Execute(T stateMachine, Event event,
Object parameter) in :line 0
at Magnum.StateMachine.State1.RaiseEvent(T instance, BasicEvent1 eevent, Ob
ject value) in :line 0
at Magnum.StateMachine.StateMachine`1.RaiseEvent(Event raised) in :line 0
at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(
IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInCont
ext, Object[]& outArgs)
at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes
sage msg, Int32 methodPtr, Boolean fExecuteInContext)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req
Msg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgDa
ta, Int32 type)
at Topshelf.Internal.ServiceControllerProxy.Start()
at Topshelf.Internal.ServiceCoordinator.Start() in d:\dev\open-source\topshel
f\src\Topshelf\Internal\ServiceCoordinator.cs:line 54
at Topshelf.Internal.Hosts.ConsoleHost.Run() in d:\dev\open-source\topshelf\s
rc\Topshelf\Internal\Hosts\ConsoleHost.cs:line 53
at NServiceBus.Host.Program.Main(String[] args) in d:\BuildAgent-02\work\20b5
f701adefe8f8\src\host\NServiceBus.Host\Program.cs:line 103
When NserviceBus host starts it tries to retrieve all types from assemblies you specify.
In the sample you provide it uses NServiceBus.Configure.WithWeb() method.
This is the same as to call NServiceBus.Configure.With(AppDomain.CurrentDomain.DynamicDirectory)
You get the excpetion because "itextsharp.dll" cannot be loaded to AppDomain (this is done by calling Assembly.LoadFrom(file.FullName) method).
To fix the issue, you may manually specify assemblies you need to scan by using one of NServiceBus.Configure.With() overloads.