Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

NAV 2018 (CU8) - Configuring Time Out and Reconnect

Posted on by Microsoft Employee

Hi,

I need to configure a time out after 15 minutes inactivity. Actually, that works fine by configuring the Idle Client Timeout in NAV Server. 

If a user continues his work after the timeout, NAV asks the following question:

<The server.... is either unavailable or your connection has beem lost. Do you want to attempt to reconnect?>

After clicking on Yes, the following error occurs:

<The session could not be retrieved from the server. The application will close.>

How can the NAV Server configured that the reconnection works fine. I defined the Reconnect Period to 5 min and I am sure I try to reconnect less then 5 minutes after time out.

Thanks and best regards

Michael

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: NAV 2018 (CU8) - Configuring Time Out and Reconnect

    I found this event in event log:

    Type: Microsoft.Dynamics.Nav.Client.NavClientClosingException

    Fatal: False

    ShowError: True

    Message: <ii>The session could not be retrieved from the server. The application will close.</ii>

    StackTrace:

        at Microsoft.Dynamics.Nav.Client.WinClient.ExceptionHandler.DoExecute(Func`1 execute)

        at Microsoft.Dynamics.Nav.Client.WinClient.ExceptionHandler.DoRethrowWithCatchException(Exception exception, Boolean designMode)

        at Microsoft.Dynamics.Nav.Client.WinClient.ExceptionHandler.WinFormsDispatcherUnhandledException(Object sender, DispatcherUnhandledExceptionEventArgs eventArgs)

        at Microsoft.Dynamics.Framework.UI.WinForms.WinFormsDispatcher.HandleDispatcherException(Object sender, Exception e)

        at System.Windows.Forms.Application.ThreadContext.OnThreadException(Exception t)

        at System.Windows.Forms.Control.WndProcException(Exception e)

        at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

        at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)

        at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)

        at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)

        at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)

        at Microsoft.Dynamics.Nav.Client.WinClient.NavWinFormsClientSession.RunMessagePump()

        at Microsoft.Dynamics.Nav.Client.WinClient.NavWinFormsClientSession.RunCore()

        at Microsoft.Dynamics.Nav.Client.WinClient.NavClientErrorHandler.ExecuteAndCatchExceptions(Func`1 execute)

    Source: Microsoft.Dynamics.Nav.Client.WinClient

    HResult: -2146233088

    ----------------------------------

    Type: Microsoft.Dynamics.Nav.Types.NavConnectionLostException

    Message: <ii>The session could not be retrieved from the server. The application will close.</ii>

    StackTrace:

        at Microsoft.Dynamics.Nav.Client.WinClient.ExceptionHandler.<>c__DisplayClass11_0.<DoRethrowWithCatchException>b__0()

        at Microsoft.Dynamics.Nav.Client.WinClient.NavClientErrorHandler.ExecuteAndCatchExceptions(Func`1 execute)

    Source: Microsoft.Dynamics.Nav.Client.WinClient

    HResult: -2146233088

    ----------------------------------

    Type: Microsoft.Dynamics.Nav.Types.NavConnectionLostException

    Message: <ii>The session could not be retrieved from the server. The application will close.</ii>

    StackTrace:

        at Microsoft.Dynamics.Nav.Client.ConnectionStateManager.ServerReconnectLoop(DateTime gracePeriodEnd)

        at Microsoft.Dynamics.Nav.Client.ConnectionStateManager.Reconnect(Boolean timeout)

        at Microsoft.Dynamics.Nav.Client.ConnectionStateManager.HandleCommunicationFailure[T](BeginCallServerMethod beginCallServerMethod, EndCallServerMethod`1 endCallServerMethod, ServerCallOptions options, Exception e, Int32 messageNumber, String sessionId)

        at Microsoft.Dynamics.Nav.Client.ConnectionStateManager.CallServer[T](BeginCallServerMethod beginCallServerMethod, EndCallServerMethod`1 endCallServerMethod, ServerCallOptions options)

        at Microsoft.Dynamics.Nav.Client.ServiceConnection.CallServer[T](BeginCallServerMethod beginCallServerMethod, EndCallServerMethod`1 endCallServerMethod)

        at Microsoft.Dynamics.Nav.Client.MetadataHandler.LoadAndCacheMetadataForPageAndAllItsDependencies(Int32 pageId, String personalizationId)

        at Microsoft.Dynamics.Nav.Client.MetadataHandler.GetMasterPage(Int32 pageId, String personalizationId, Boolean applyPersonalization)

        at Microsoft.Dynamics.Nav.Client.FormBuilder.BuilderSession.CreateLogicalForm(Int32 formId, FormState formState, Int32 retryCounter)

        at Microsoft.Dynamics.Nav.Client.Actions.NavOpenTaskPageAction.CreateForm(UISession uiSession, NavBindingManager parentBindingManager, FormState formState)

        at Microsoft.Dynamics.Nav.Client.Actions.NavOpenTaskPageAction.InvokeCore(LogicalControl logicalControl, Object state, UISession uiSession)

        at Microsoft.Dynamics.Framework.UI.LogicalAction.InvokeCoreWithErrorHandling(LogicalControl logicalControl, Object state, UISession uiSession)

        at Microsoft.Dynamics.Framework.UI.LogicalAction.DoInvoke(LogicalControl logicalControl, IDictionary state, UISession uiSession)

        at Microsoft.Dynamics.Framework.UI.Windows.ActionsHelper.<>c__DisplayClass7_0.<ModalitySafeInvoke>b__0()

        at Microsoft.Dynamics.Framework.UI.Windows.ActionsHelper.ModalitySafe(Action action)

        at Microsoft.Dynamics.Framework.UI.Windows.ActionsHelper.ModalitySafeInvoke(LogicalAction action, LogicalControl control)

        at Microsoft.Dynamics.Framework.UI.WinForms.RepeaterControlAdapter.DataGrid_PerformCellAction(Object sender, DataGridViewCellEventArgs e)

        at Microsoft.Dynamics.Framework.UI.WinForms.Controls.BusinessGridView.OnPerformCellAction(DataGridViewCellEventArgs e)

        at Microsoft.Dynamics.Framework.UI.WinForms.Controls.BusinessGridView.WndProc(Message& m)

        at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

    Source: Microsoft.Dynamics.Nav.Client.ServiceConnection

    HResult: -2146233088

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