Using external apps causes unhandled exception

Description

I use externals often and they all fail if I choose an external app. This specific exception comes from a Remote Desktop connection where I have a user name defined as administrator. I have an external app that references c:\windows\explorer.exe. I've tested with and without any arguments. Normally I would have "
%HOSTNAME%" as its argument.

Summary of exception is
Unable to cast object of type
'System.Windows.Forms.ToolStripMenuItem' to type 'System.Windows.Forms.Control'

Details:
ee the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

  •  

    •  

      •  

        •  

          •  

            •  

              •  

                •  

                  •  

                    •  

                      •  

                        •  

                          •  

                            • Exception Text **************
                              System.InvalidCastException: Unable to cast object of type 'System.Windows.Forms.ToolStripMenuItem' to type 'System.Windows.Forms.Control'.
                              at mRemoteNG.UI.Window.ConnectionTreeWindow.cMenTreeToolsExternalAppsEntry_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)

  •  

    •  

      •  

        •  

          •  

            •  

              •  

                •  

                  •  

                    •  

                      •  

                        •  

                          •  

                            • Loaded Assemblies **************
                              mscorlib
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1076.0 built by: NETFXREL3STAGE
                              CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
                              ----------------------------------------
                              mRemoteNG
                              Assembly Version: 1.74.5995.30386
                              Win32 Version: 1.74.5995.30386
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/mRemoteNG.exe
                              ----------------------------------------
                              System.Windows.Forms
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1055.0 built by: NETFXREL2
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
                              ----------------------------------------
                              System
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1075.0 built by: NETFXREL3STAGE
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
                              ----------------------------------------
                              System.Drawing
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1068.2 built by: NETFXREL3STAGE
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
                              ----------------------------------------
                              System.Configuration
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1055.0 built by: NETFXREL2
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
                              ----------------------------------------
                              System.Core
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1055.0 built by: NETFXREL2
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
                              ----------------------------------------
                              System.Xml
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1067.0 built by: NETFXREL3STAGE
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
                              ----------------------------------------
                              log4net
                              Assembly Version: 1.2.15.0
                              Win32 Version: 1.2.15.0
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/log4net.DLL
                              ----------------------------------------
                              mRemoteNG.resources
                              Assembly Version: 1.74.5995.30386
                              Win32 Version: 1.74.5995.30386
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/en-US/mRemoteNG.resources.DLL
                              ----------------------------------------
                              System.Management
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1055.0 built by: NETFXREL2
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/System.Management/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Management.dll
                              ----------------------------------------
                              WeifenLuo.WinFormsUI.Docking
                              Assembly Version: 2.9.0.0
                              Win32 Version: 2.9.0.0
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/WeifenLuo.WinFormsUI.Docking.DLL
                              ----------------------------------------
                              WeifenLuo.WinFormsUI.Docking.ThemeVS2012Light
                              Assembly Version: 2.9.0.0
                              Win32 Version: 2.9.0.0
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/WeifenLuo.WinFormsUI.Docking.ThemeVS2012Light.DLL
                              ----------------------------------------
                              MagicLibrary
                              Assembly Version: 1.7.4.0
                              Win32 Version: 1.7.4.0
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/MagicLibrary.DLL
                              ----------------------------------------
                              WindowsBase
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1080.0 built by: NETFXREL3STAGE
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/WindowsBase/v4.0_4.0.0.0__31bf3856ad364e35/WindowsBase.dll
                              ----------------------------------------
                              Accessibility
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1055.0 built by: NETFXREL2
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_MSIL/Accessibility/v4.0_4.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
                              ----------------------------------------
                              FilteredPropertyGrid
                              Assembly Version: 1.0.2258.31541
                              Win32 Version: 1.0.0.0
                              CodeBase: file:///C:/mount/1/0/Program%20Files/mRemoteNG/FilteredPropertyGrid.DLL
                              ----------------------------------------
                              System.Web
                              Assembly Version: 4.0.0.0
                              Win32 Version: 4.6.1055.0 built by: NETFXREL2
                              CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GAC_32/System.Web/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Web.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.

Environment

Win 7 x64, portable version

Status

Assignee

David Sparer

Reporter

klui

Labels

None

Components

Fix versions

Affects versions

Priority

Major
Configure