Elements v10 Beta with VS2015 Design Time Exception Error on attaching a method to main window

wpf

(Bob Russell) #1

With a newly created “empty” WPF project, double clicking in Solution Explorer on any method re the Main Window to create a a method stub produces an Exception

System.NullReferenceException
Object reference not set to an instance of an object.
at RemObjects.Oxygene.Code.CombinedParsedType.HasMember(String aName)
at RemObjects.Oxygene.VisualStudio.OxygeneProject.DesignerContextProviders.OxygeneEventBindingProvider.CreateUniqueMethodName(String objectName, EventDescription eventDescription)
at Microsoft.VisualStudio.DesignTools.XamlDesignerHost.Platform.DesignerContextCodeContext.Microsoft.VisualStudio.DesignTools.DesignerContract.IHostCodeContext.CreateUniqueMethodName(String objectName, IHostCodeEvent codeEvent)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.RemoteHostCodeContext.<>c__DisplayClass14_0.<Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.IRemoteHostCodeContext.CreateUniqueMethodName>b__0()
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.ThreadMarshaler.<>c__DisplayClass48_0`1.b__0()
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.Call.InvokeWorker()

System.NullReferenceException
Object reference not set to an instance of an object.

Server stack trace:
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.WaitForCompletion(NestedCallContext nestedCallContext, BlockingCall call, WaitHandle timeoutSignal)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.MarshalInSynchronous(Action action, Int32 targetApartmentId, CancellationToken cancelToken, CallModality callModality, String methodName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.MarshalIn(Action action, Int32 targetApartmentId, CancellationToken cancelToken, CallSynchronizationMode syncMode, CallModality callModality, String methodName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.ThreadMarshaler.MarshalIn(IRemoteObject targetObject, Action action, CallSynchronizationMode syncMode, CallModality callModality, ApartmentState apartmentState, String memberName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.ThreadMarshaler.MarshalIn[TResult](IRemoteObject targetObject, Func`1 func, CallModality callModality, ApartmentState apartmentState, String memberName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.RemoteHostCodeContext.Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.IRemoteHostCodeContext.CreateUniqueMethodName(String objectName, String eventName, RemoteHostParameter[] parameters, String returnType)
at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Object[]& outArgs)
at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMessage msg)

Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.IRemoteHostCodeContext.CreateUniqueMethodName(String objectName, String eventName, RemoteHostParameter[] parameters, String returnType)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.LocalHostCodeContext.<>c__DisplayClass15_0.<Microsoft.VisualStudio.DesignTools.DesignerContract.IHostCodeContext.CreateUniqueMethodName>b__0(IRemoteHostCodeContext cxt)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.ThreadMarshaler.<>c__DisplayClass32_0`2.b__0()
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.Call.InvokeWorker()

System.NullReferenceException
Object reference not set to an instance of an object.
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.WaitForCompletion(NestedCallContext nestedCallContext, BlockingCall call, WaitHandle timeoutSignal)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.MarshalOutSynchronous(Action action, Int32 targetApartmentId, WaitHandle aborted, WaitHandle timeoutSignal, CancellationToken cancelToken, String methodName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.STAMarshaler.MarshalOut(Action action, Int32 targetApartmentId, WaitHandle aborted, CancellationToken cancelToken, CallSynchronizationMode syncMode, WaitHandle timeoutSignal, String methodName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.ThreadMarshaler.MarshalOut[TValue](RemoteHandle1 targetObject, Action action, CallSynchronizationMode syncMode, ApartmentState apartmentState, String methodName, String filePath, Int32 lineNumber) at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.ThreadMarshaler.MarshalOut[TResult,TValue](RemoteHandle1 targetObject, Func`2 func, CallSynchronizationMode syncMode, ApartmentState apartmentState, String methodName, String filePath, Int32 lineNumber)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.Remoting.LocalHostCodeContext.Microsoft.VisualStudio.DesignTools.DesignerContract.IHostCodeContext.CreateUniqueMethodName(String objectName, IHostCodeEvent codeEvent)
at Microsoft.VisualStudio.DesignTools.Designer.UI.PropertyInspector.CodeContext.CreateUniqueMethodName(ISourceItemContext item, String typeName, String objectName, IEvent eventKey)
at Microsoft.VisualStudio.DesignTools.Designer.UI.PropertyInspector.EventHandlerProvider.CreateUniqueMethodName(String objectName, IEvent eventKey)
at Microsoft.VisualStudio.DesignTools.Designer.UI.PropertyInspector.EventHandlerModel.GenerateMethodName()
at Microsoft.VisualStudio.DesignTools.Designer.UI.PropertyInspector.EventHandlerModel.GenerateAndCommit()
at Microsoft.VisualStudio.DesignTools.Designer.UI.PropertyInspector.EventHandlerModel.<get_GenerateAndCommitCommand>b__14_1(Object arg)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.DispatcherOperation.InvokeImpl()
at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(Object state)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at MS.Internal.CulturePreservingExecutionContext.Run(CulturePreservingExecutionContext executionContext, ContextCallback callback, Object state)
at System.Windows.Threading.DispatcherOperation.Invoke()
at System.Windows.Threading.Dispatcher.ProcessQueue()
at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
at System.Windows.Application.RunDispatcher(Object ignore)
at System.Windows.Application.RunInternal(Window window)
at System.Windows.Application.Run(Window window)
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.DesignerProcess.RunApplication()
at Microsoft.VisualStudio.DesignTools.DesignerContract.Isolation.DesignerProcess.<>c__DisplayClass5_0.b__0()
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()

===========================================

Is this something I’m doing incorrectly?

Thanks.


(RemObjects) #2

Thanks, logged as bugs://79261


(RemObjects) #3

bugs://79261 got closed with status fixed.


(Bob Russell) #4

Just installed the latest beta for oxygene. I tried to add a window method to a WPF project by double clicking as described above, and still got the unhandled exception. Is the bug fixed in RemObjects Elements - 10.0.0.2247?

Thanks


(marc hoffman) #5

Which version did you install? — .2247 is the latest beta build.


(Bob Russell) #6

Hi Marc, .2247 according to the exe name, installed against an existing VS2015, then opened the pre-existing project, and tried to add a method to the main window.

Bob


(RemObjects) #7

bugs://79261 got reopened.


(marc hoffman) #8

OK, gotcha. I’ve re-=opened the issue, thanx for letting us know it’s not fully fixed.


(RemObjects) #9

bugs://79261 got closed with status fixed.


(Bob Russell) #10

Confirmed fixed. Many thanks.