RTC Connection stopped working

vaprogvaprog Member Posts: 1,116
edited 2018-09-17 in NAV Three Tier
Hello

I have a rather strange issue which I failed to resolve so far.

I have been designing a page part for a role center. In order to test my changes I closed my running windows RTC and tried to restart it, which failed.
Error Message (in German (don't know how to switch the language in this non-functional state:

Microsoft Dynamics NAV
The server "net.tcp://<host>:7046/<instance>/Service" is either unavailable or your connection has been lost. Do you want to attempt to reconnect?
Ja Nein
Answering Yes gets me the following message:

Microsoft Dynamics NAV
The session could not be retrieved from the server. The application will close.
OK
On the client, a NavConnectionLostException is logged in the event log.

On the server, event 216 from source MicrosoftDynamicsNavServer$<instance> is logged in the Application log:
Server instance: <instance>
Tenant ID:
User:
Type: System.InvalidOperationException
Message: There is an error in XML document (1, 4096).
StackTrace:
at System.Xml.Serialization.XmlSerializer.Deserialize(XmlReader xmlReader, String encodingStyle, XmlDeserializationEvents events)
at Microsoft.Dynamics.Nav.Types.Metadata.MetaPage.CreatePageDefinition(XmlSerializer pageDefinitionSerializer, XmlReader reader)
at Microsoft.Dynamics.Nav.Runtime.NCLMetaForm.LoadMetadata()
at Microsoft.Dynamics.Nav.Runtime.NCLMetaApplicationObject.Populate()
at Microsoft.Dynamics.Nav.Runtime.NCLMetadata.GetMetaApplicationObjectInternal(ApplicationObjectId appObjectId, Boolean requireCompiled, Boolean onlySearchCache, Int32 appGroupId)
at Microsoft.Dynamics.Nav.Runtime.NCLMetadata.GetMetaApplicationObject(ObjectType objectType, Int32 objectId, Int32 appGroupId, Boolean requireCompiled, Boolean onlySearchCache)
at Microsoft.Dynamics.Nav.Runtime.AssemblyGetter.InitializeStaticAssembly(ObjectType objectType)
at Microsoft.Dynamics.Nav.Runtime.AssemblyGetter.<CompileBusinessApplication>b__2(NavTenant tenant, NavSession session)
at Microsoft.Dynamics.Nav.Runtime.NavTenant.Microsoft.Dynamics.Nav.Runtime.ITenantSessionHandler.RunTenantActionInSystemSession(Action`2 action, Boolean throwExceptions)
at Microsoft.Dynamics.Nav.Runtime.AssemblyGetter.CompileBusinessApplication()
Source: System.Xml
HResult: -2146233079
Type: System.InvalidOperationException
Message: Instance validation error: 'Record' is not a valid value for DataType.
StackTrace:
at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderPageDefinition.Read81_DataType(String s)
at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderPageDefinition.Read83_DataFieldDefinition(Boolean isNullable, Boolean checkType)
at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderPageDefinition.Read94_PageDefinition(Boolean isNullable, Boolean checkType)
at Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderPageDefinition.Read95_PageDefinition()
Source: Microsoft.GeneratedCode
HResult: -2146233079

Here's what I tried so far:
  • I checked all .xml and .config files in the service installation folder, the instance folder, the server's folder tree in %ProgramData%, NAV's folder in the service users and client user's %APPDATA% on the server. On the client I checked the client's config and deleted PersonalizationStore.xml
  • The error is not user or client computer specific (i.e. other users get the same error on their own workstation).
  • I tried recompiling all objects and syncing the database
  • Starting a different profile using the -profile parameter when starting RTC works
  • I deleted records in tables "Profile Metadata", "User Personalization", "User Metadata", and "Page Data Personalization"

Does anyone have any suggestion on what else I might try to get my role center working again?

Best Answers

  • vaprogvaprog Member Posts: 1,116
    Answer ✓
    I found the culprit. It turned out to be the Visible property on one of the fields (a cue) on the CardPart page. I had used a boolean field of a record variable. Everything is all right with a global variable of type boolean instead.

    Btw. I was using NAV 2016 CU19

Answers

  • vaprogvaprog Member Posts: 1,116
    Answer ✓
    I found the culprit. It turned out to be the Visible property on one of the fields (a cue) on the CardPart page. I had used a boolean field of a record variable. Everything is all right with a global variable of type boolean instead.

    Btw. I was using NAV 2016 CU19
  • vaprogvaprog Member Posts: 1,116
    You must have some code in your new pagepart that is causing this. I would remove everything from the pagepart recompile and check that the role center is working again. Then add small chuncks of code and see when it fails.

    Yes, that's exactly what I did after I wrote this request for help. I trusted the compiler not complaining, paired with the severity of the fault, too much.

Sign In or Register to comment.