Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

Extension 2.0 - Running Debug gives me "Sorry that didn't work." An error has occurred

Posted on by 90

So I am trying to run my extension with debugging and every time it comes up with Sorry that didn't work. An Error has occurred. - Restart

When I run F6 the Web Client opens just fine and my code is loaded and I can run my code just fine.  I just want to be able to debug it for an error I'm receiving.  How can I get F5 to run so that I can debug my code?

Here are the Event View Warnings:

Server instance: DynamicsNAV110
Tenant: <ii>default</ii>
<ii>Session type: WebClient
Session ID: 340
This license is not compatible with this version of Dynamics NAV.</ii>

Server instance: DynamicsNAV110
Tenant: <ii>default</ii>
<ii>Session type: WebServiceClient
Session ID: 330
This license is not compatible with this version of Dynamics NAV.</ii>

Here are my Event viewer errors.

Error accessing Website 
Raw Url: 
Url: 
Type: Microsoft.Dynamics.Nav.Types.Exceptions.NavServerSessionException
Message: The server "DynamicsNAV110" was unable to process the request. The application will close.
StackTrace:
   at Microsoft.Dynamics.Nav.Client.ConnectionEstablisher.OpenConnection[TChannel](ConnectFailedEventArgs connectFailedArgs, ConnectionRequest connectionRequest, ConnectionOptions connectionOptions, SpnSetting spnSettingToTry, Boolean allowSpnSettingsSwap, UserSettings& userSettings)
   at Microsoft.Dynamics.Nav.Client.ConnectionEstablisher.OpenConnection[TChannel](ConnectionRequest connectionRequest, ConnectionOptions connectionOptions, UserSettings& userSettings)
   at Microsoft.Dynamics.Nav.Client.ServiceConnection.OpenConnection()
   at Microsoft.Dynamics.Nav.Client.ServiceConnection.Initialize()
   at Microsoft.Dynamics.Nav.Client.FormBuilder.BuilderSessionInitializer.OpenConnectionToServer()
   at Microsoft.Dynamics.Nav.Client.FormBuilder.BuilderSessionInitializer.InitializeCore()
   at Microsoft.Dynamics.Nav.Client.FormBuilder.BuilderSessionInitializer.Initialize()
   at Microsoft.Dynamics.Framework.UI.UISession.Initialize()
   at Microsoft.Dynamics.Nav.Client.Web.NavWebUISessionInitializer.InitializeCore(UISession session)
   at Microsoft.Dynamics.Nav.WebClient.NavWebClientUISessionInitializer.InitializeCore(UISession session)
   at Microsoft.Dynamics.Nav.Client.Web.NavWebUISessionInitializer.Initialize(UISession session)
   at Microsoft.Dynamics.Framework.UI.Client.OpenFormExecutionStrategy.TryInitializeUiSession(UISession session)
   at Microsoft.Dynamics.Framework.UI.Web.WebOpenFormExecutionStrategy.TryInitializeUiSession(UISession session)
   at Microsoft.Dynamics.Framework.UI.Client.OpenFormExecutionStrategy.Execute()
   at Microsoft.Dynamics.Framework.UI.InteractionManager.<>c__DisplayClass8_0.<InvokeInteractions>b__3()
Source: Microsoft.Dynamics.Nav.Client.ServiceConnection----------------------------------
Type: Microsoft.Dynamics.Nav.Types.Exceptions.NavServerSessionException
Message: The server "DynamicsNAV110" was unable to process the request. The application will close.
StackTrace:

Source: ----------------------------------
Type: System.InvalidOperationException
Message: Dynamic operations can only be performed in homogenous AppDomain.
StackTrace:
   at System.Runtime.CompilerServices.CallSiteBinder.BindCore[T](CallSite`1 site, Object[] args)
   at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1)
   at Microsoft.Dynamics.Nav.Service.Dev.Web.Controllers.DebuggerHub.OnDebuggeeConnected(Object sender, DebugSessionStartEventArgs eventArgs)
   at Microsoft.Dynamics.Nav.Runtime.Debugger.DebugRuntimeManager.OnDebuggingSessionStarted(DebugSessionStartEventArgs e)
   at Microsoft.Dynamics.Nav.Runtime.Debugger.DebugRuntimeManager.CreateRuntime(String debuggingContext, NavSession session, Boolean waitForDebugAdapterConfiguration)
   at Microsoft.Dynamics.Nav.Runtime.NavSession.StartDebuggingSession(String debuggingContext, Boolean waitForDebugAdapterConfiguration)
   at Microsoft.Dynamics.Nav.Service.NSService.OpenConnection(ConnectionRequest connectionRequest)
   at SyncInvokeOpenConnection(Object , Object[] , Object[] )
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
   at Microsoft.Dynamics.Nav.Service.ServiceOperationInvoker.ErrorMappingCombinator(ServiceOperation innerOperation, NSServiceBase serviceInstance, MethodBase syncMethod, Object[] inputs, Object[]& outputs)
Source: System.Core

Server instance: DynamicsNAV110
Tenant ID: 
<ii>User: CBIZ\gnilsen0
Type: System.InvalidOperationException
Message: <ii>Dynamic operations can only be performed in homogenous AppDomain.</ii>
StackTrace:
     at System.Runtime.CompilerServices.CallSiteBinder.BindCore[T](CallSite`1 site, Object[] args)
     at System.Dynamic.UpdateDelegates.UpdateAndExecute2[T0,T1,TRet](CallSite site, T0 arg0, T1 arg1)
     at Microsoft.Dynamics.Nav.Service.Dev.Web.Controllers.DebuggerHub.OnDebuggeeConnected(Object sender, DebugSessionStartEventArgs eventArgs)
     at Microsoft.Dynamics.Nav.Runtime.Debugger.DebugRuntimeManager.OnDebuggingSessionStarted(DebugSessionStartEventArgs e)
     at Microsoft.Dynamics.Nav.Runtime.Debugger.DebugRuntimeManager.CreateRuntime(String debuggingContext, NavSession session, Boolean waitForDebugAdapterConfiguration)
     at Microsoft.Dynamics.Nav.Runtime.NavSession.StartDebuggingSession(String debuggingContext, Boolean waitForDebugAdapterConfiguration)
     at Microsoft.Dynamics.Nav.Service.NSService.OpenConnection(ConnectionRequest connectionRequest)
     at SyncInvokeOpenConnection(Object , Object[] , Object[] )
     at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]& outputs)
     at Microsoft.Dynamics.Nav.Service.ServiceOperationInvoker.ErrorMappingCombinator(ServiceOperation innerOperation, NSServiceBase serviceInstance, MethodBase syncMethod, Object[] inputs, Object[]& outputs)
Source: System.Core
HResult: -2146233079
</ii>

Server instance: DynamicsNAV110
Tenant ID: 
<ii>User: CBIZ\gnilsen0
Type: System.NullReferenceException
Message: <ii>Object reference not set to an instance of an object.</ii>
StackTrace:
     at Microsoft.Dynamics.Nav.Runtime.Debugger.DebugRuntime.EnsureDetachedFromConnection(NavSession session)
     at Microsoft.Dynamics.Nav.Runtime.NavSession.ShutdownDebuggingEnvironment(NavBaseException& firstCaughtException)
     at Microsoft.Dynamics.Nav.Runtime.NavSession.InnerDispose()
     at Microsoft.Dynamics.Nav.Runtime.NavSession.<DisposeAsync>d__127.MoveNext()
Source: Microsoft.Dynamics.Nav.Ncl
HResult: -2147467261
</ii>

Server instance: DynamicsNAV110
Tenant ID: 
<ii>User: CBIZ\gnilsen0
Type: System.NullReferenceException
Message: <ii>Object reference not set to an instance of an object.</ii>
StackTrace:
     at Microsoft.Dynamics.Nav.Runtime.Debugger.DebugRuntime.EnsureDetachedFromConnection(NavSession session)
     at Microsoft.Dynamics.Nav.Runtime.NavSession.ShutdownDebuggingEnvironment(NavBaseException& firstCaughtException)
     at Microsoft.Dynamics.Nav.Runtime.NavSession.InnerDispose()
     at Microsoft.Dynamics.Nav.Runtime.NavSession.<DisposeAsync>d__127.MoveNext()
Source: Microsoft.Dynamics.Nav.Ncl
HResult: -2147467261
</ii>


*This post is locked for comments

  • Marcellus Profile Picture
    Marcellus 2,735 on at
    RE: Extension 2.0 - Running Debug gives me "Sorry that didn't work." An error has occurred

    Hi Gnilsen, great news, happy debugging :)

  • gnilsen Profile Picture
    gnilsen 90 on at
    RE: Extension 2.0 - Running Debug gives me "Sorry that didn't work." An error has occurred

    Thank you so much!  It was set to true.  Once I set it to false then I was able to debug.  

  • Verified answer
    Marcellus Profile Picture
    Marcellus 2,735 on at
    RE: Extension 2.0 - Running Debug gives me "Sorry that didn't work." An error has occurred

    Hi Gnilsen,

    In the "C:\Program Files\Microsoft Dynamics NAV\110\Service\Microsoft.Dynamics.Nav.Server.exe.config"

    did you set the  the enabled value on the following key to false? <NetFx40_LegacySecurityPolicy enabled="false"/>

    After updating the value you will also need to restart your service.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans