हमें हमारे विंडोज़ फॉर्म एप्लिकेशन के साथ कोई समस्या हो रही है, जहां यह AccessViolationException के एक अनचाहे अपवाद के कारण समाप्त हो रहा है कि स्टैक ट्रेस इंगित कर रहा है टूलटिप नियंत्रण में होता है।टूलटिप पर AccessViolationException COMCTL32.dll - .NET 4.0
त्रुटि में एप्लिकेशन में अलग-अलग समय होता है, और वर्तमान में हम इसे विश्वसनीय रूप से पुन: उत्पन्न करने में सक्षम नहीं हैं। इस चरण में यह केवल विंडोज 7 पर उत्पादन में होता है और केवल कुछ उपयोगकर्ताओं के लिए होता है, लेकिन अन्य नहीं - यहां तक कि उन उपयोगकर्ताओं के बीच भी जो एप्लिकेशन को उसी तरह उपयोग करते हैं। यह मशीन से संबंधित प्रतीत होता है और इसलिए हमने यह सुनिश्चित किया है कि ग्राफिक्स ड्राइवर अद्यतित है।
Application: <Application>.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.AccessViolationException
Stack:
at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr, IntPtr, Int32, IntPtr, IntPtr)
at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.ToolTip.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.ToolTip+ToolTipNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG ByRef)
at System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr, Int32, Int32)
at System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
at System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
at <Company>.Windows.Forms.<Application>.Startup.Main(System.String[])
और एक comctl32.dll से संबंधित:
Faulting application name: <Application>.exe, version: 7.13.0.2086, time stamp: 0x4ec5e710
Faulting module name: comctl32.dll, version: 5.82.7601.17514, time stamp: 0x4ce7b82c
Exception code: 0xc0000005
Fault offset: 0x00043286
Faulting process id: 0xcdc
Faulting application start time: 0x01cca96312446309
Faulting application path: C:\Program Files\<Company>\Client\<Application>.exe
Faulting module path: C:\Windows\WinSxS\x86_microsoft.windows.common-controls_6595b64144ccf1df_5.82.7601.17514_none_ec83dffa859149af\comctl32.dll
Report Id: b425143c-1575-11e1-bccf-6c626d955bf1
पहले स्टैक ट्रेस परिवर्तन
ईवेंट लॉग में, हमेशा लॉग इन, एक हमारे आवेदन से संबंधित 2 अलग त्रुटियाँ हैं वर्कफ़्लो में त्रुटि कहां होती है, इस पर निर्भर करता है कि, स्टैक पर शीर्ष 9 आइटम हमेशा समान होते हैं, अंतर आमतौर पर एक शोडियलॉग कॉल होता है जो मुख्य() विधि और RunMessageLoop विधि के बीच दिखाई देता है। उदाहरण के लिए:
Application: <Application>.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.AccessViolationException
Stack:
at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr, IntPtr, Int32, IntPtr, IntPtr)
at System.Windows.Forms.NativeWindow.DefWndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.ToolTip.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.ToolTip+ToolTipNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG ByRef)
at System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr, Int32, Int32)
at System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
at System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
at System.Windows.Forms.Application.RunDialog(System.Windows.Forms.Form)
at System.Windows.Forms.Form.ShowDialog(System.Windows.Forms.IWin32Window)
at System.Windows.Forms.Form.ShowDialog()
at <Company>.Windows.Forms.<Application>.ApplicationForm.<EventSubscribingMethod>(System.Object, System.EventArgs)
at <Company>.<Application>.<Class1>.RaiseShowResultDialogNowEvent()
at System.Windows.Forms.Control.InvokeMarshaledCallbackDo(ThreadMethodEntry)
at System.Windows.Forms.Control.InvokeMarshaledCallbackHelper(System.Object)
at System.Threading.ExecutionContext.runTryCode(System.Object)
at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode, CleanupCode, System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
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.Forms.Control.InvokeMarshaledCallback(ThreadMethodEntry)
at System.Windows.Forms.Control.InvokeMarshaledCallbacks()
at System.Windows.Forms.Control.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.ScrollableControl.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.Form.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.Control+ControlNativeWindow.OnMessage(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.Control+ControlNativeWindow.WndProc(System.Windows.Forms.Message ByRef)
at System.Windows.Forms.NativeWindow.Callback(IntPtr, Int32, IntPtr, IntPtr)
at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG ByRef)
at System.Windows.Forms.Application+ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr, Int32, Int32)
at System.Windows.Forms.Application+ThreadContext.RunMessageLoopInner(Int32, System.Windows.Forms.ApplicationContext)
at System.Windows.Forms.Application+ThreadContext.RunMessageLoop(Int32, System.Windows.Forms.ApplicationContext)
at <Company>.Windows.Forms.<Application>.Portal.Startup.Main(System.String[])
---- अद्यतन ----
मैं शामिल करने के लिए मुख्य रूप से कोड के कुछ, मैं सभी कोड शामिल करने के लिए नहीं करना चाहती एक अनुरोध किया है, लेकिन एक उद्धरण है :
<System.STAThread()> _
Public Shared Function Main(ByVal args() As String) As Integer
-- Perform startup validation, setup logging framework, etc
...
Dim appLife as new ApplicationContext(myStartupForm)
Application.Run(appLife)
Return 0
End Function
कुछ अतिरिक्त नोट्स:
- हम एमएस पैटर्न और आचरण से यूआई प्रक्रिया आवेदन ब्लॉक का उपयोग कर रहे
- हम http://www.codeproject.com/KB/combobox/extending_combobox.aspx
पर नियंत्रण के एक जोड़े में WndProc ओवरराइड करते हैं, किसी को भी पता है यह क्या कारण हो सकता है कोड परियोजना से CheckBoxComboBox सहित?
धन्यवाद,
है 'मुख्य में कोड दिखाएं()' करें। ऐसा लगता है कि आप 'एप्लिकेशन.रुन' नहीं बुला रहे हैं। – leppie
अतिरिक्त जानकारी के लिए धन्यवाद। '0xc0000005' मूल 'NullReferenceException' है। जैसा कि आप कह रहे हैं कि आप 'WndProc' ओवरराइड कर रहे हैं, मैं शायद किसी भी नल पॉइंटर्स के लिए वहां देखता हूं। – leppie