How to fix run time Error 1026

Answered How to fix run time Error 1026

  • 7 августа 2012 г. 7:22
     
     

    Some times my application is crashing with Event id 1026 seen in EventViewer.

    Below the Event Log report:

    _____________________________

    Application: DSMAgent.exe
    Framework Version: v4.0.30319
    Description: The process was terminated due to an unhandled exception.
    Exception Info: System.AccessViolationException
    Stack:
       at System.Threading.Thread.InternalCrossContextCallback(System.Runtime.Remoting.Contexts.Context, IntPtr, Int32, System.Threading.InternalCrossContextDelegate, System.Object[])
       at System.Runtime.Remoting.Channels.CrossContextChannel.SyncProcessMessage(System.Runtime.Remoting.Messaging.IMessage)
       at System.Runtime.Remoting.Proxies.RemotingProxy.CallProcessMessage(System.Runtime.Remoting.Messaging.IMessageSink, System.Runtime.Remoting.Messaging.IMessage, System.Runtime.Remoting.Contexts.ArrayWithSize, System.Threading.Thread, System.Runtime.Remoting.Contexts.Context, Boolean)
       at System.Runtime.Remoting.Proxies.RemotingProxy.InternalInvoke(System.Runtime.Remoting.Messaging.IMethodCallMessage, Boolean, Int32)
       at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(System.Runtime.Remoting.Proxies.MessageData ByRef, Int32)
       at Lucent.SPAT3G.HDAL.DatabaseHelper.ExecuteDataSet(System.String, System.Data.CommandType, Lucent.SPAT3G.CDAL.ErrorObject ByRef)
       at Lucent.SPAT3G.HDAL.DbHelper.ExecuteQuery(System.String, System.Data.DataTable ByRef, Lucent.SPAT3G.CDAL.ErrorObject ByRef)
       at Lucent.SPAT3G.QDAL.DsmQuery.RunNLAlert(Lucent.SPAT3G.QDAL.DSMEnumerators.Technology, System.String, System.String, Boolean)
       at Lucent.SPAT3G.QDAL.DsmQuery.DoReciprocalNLConfig(Lucent.SPAT3G.QDAL.DSMEnumerators.Technology, System.String)
       at Lucent.SPAT3G.QDAL.DsmQuery.ExecuteAlert(Lucent.SPAT3G.QDAL.DSMEnumerators.NLAlerts, Lucent.SPAT3G.QDAL.DSMEnumerators.Technology, System.String)
       at Lucent.SPAT3G.DSM.PE2.NLAnalysis.ExecuteAlert(System.String, System.String)
       at Lucent.SPAT3G.DSM.PE2.NLAnalysis.DoNLAlert(System.String)
       at Lucent.SPAT3G.DSM.PE2.PE2Wrapper.StartProcess(Lucent.SPAT3G.DSM.PE2.PE2Param)
       at Lucent.SPAT3G.DSM.Manager.DSMManager.ExecuteProcess(Lucent.SPAT3G.DSM.BLLCommon.PECommonWrap)
       at Lucent.SPAT3G.DSM.Manager.DSMManager.ExecuteProcess(Lucent.SPAT3G.DSM.BLLCommon.ProcessModule, System.Threading.Tasks.ParallelLoopState)
       at System.Threading.Tasks.Parallel+<>c__DisplayClass32`2[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].<PartitionerForEachWorker>b__30()
       at System.Threading.Tasks.Task.InnerInvokeWithArg(System.Threading.Tasks.Task)
       at System.Threading.Tasks.Task+<>c__DisplayClass7.<ExecuteSelfReplicating>b__6(System.Object)
       at System.Threading.Tasks.Task.Execute()
       at System.Threading.ExecutionContext.runTryCode(System.Object)
       at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode, CleanupCode, System.Object)
       at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
       at System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef)
       at System.Threading.Tasks.Task.ExecuteEntry(Boolean)
       at System.Threading.ThreadPoolWorkQueue.Dispatch()
       at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

    Any help is really appreciated!


    click "Proposed As Answer by" if this post solves your problem or "Vote As Helpful" if a post has been useful to you Happy Programming! Hari



    • Изменено Hariprasadbrk 7 августа 2012 г. 7:25
    •  

Все ответы

  • 7 августа 2012 г. 7:43
     
     
    Since Windows Error is related to missing DLL files, you can re-register the registry list to fix Runtime error 1026 issue. For example, if you encounter Runtime error 1026 files, to re-register the file, please do this:
    1. Click Start-Run
    2. Type in regsvr32 c:\windows\system32\dllfile
    3. Re-start your computer.

    http://www.dapfor.com/en/net-suite/net-grid/tutorial/data-binding

  • 7 августа 2012 г. 7:50
     
     

    Hi Avrillavig,
    Thanks for the reply..
    My app is working fine in some times, but some other time my app will crash with above log in Event Viewer.

    I created the app in .net 4.0.

    Which dll i need to register?

    Since i'm running Managed code.


    click "Proposed As Answer by" if this post solves your problem or "Vote As Helpful" if a post has been useful to you Happy Programming! Hari


    • Изменено Hariprasadbrk 7 августа 2012 г. 7:51
    •  
  • 7 августа 2012 г. 10:34
     
     Отвечено С кодом

    Hello Hari,

    Exception might also occured from this CrossContextChannel

    as you given the exception trace highlighted in bold

    Stack:
       at System.Threading.Thread.InternalCrossContextCallback(System.Runtime.Remoting.Contexts.Context, IntPtr, Int32, System.Threading.InternalCrossContextDelegate, System.Object[])
       at System.Runtime.Remoting.Channels.CrossContextChannel.SyncProcessMessage(System.Runtime.Remoting.Messaging.IMessage)
       at

    CrossContextChannel can use the same virtual memory in both the client and server sides of the channel, might be both client and server accessing at same time the virtual memory at that point of time System.AccessViolationException might be occurring.

    Better to create a simple application with this multi threading try to simulate the problem than it will be easier to analyze the problem and post the same code if you didn't get the solution.

    Good Luck!!!.

    and Try to share your solution after fixing also


    click "Proposed As Answer by" if this post solves your problem or "Vote As Helpful" if a post has been useful to you Happy Programming!