Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Javascript error

Posted on by Microsoft Employee

hello

i have a new error on our crm 2015 (on-premise):

when i log in and open the dashboard, i get a javascript error:

crm_2D00_javascript-error.png

can you tell me how to troubleshoot this kind of error message?

i already checked the debugging-tool in firefox and it says that the Visualization.js caused this error

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    Ist still have this issue:

    <TraceRecord xmlns="schemas.microsoft.com/.../TraceRecord&quot; Severity="Error">

    <TraceIdentifier>msdn.microsoft.com/.../System.ServiceModel.Diagnostics.ThrowingException.aspx&lt;/TraceIdentifier>

    <Description>Throwing an exception.</Description><AppDomain>/LM/W3SVC/2/ROOT-1-131384374653104357</AppDomain><Exception><ExceptionType>System.ArgumentException, mscorlib, Version=4.0.0.0, Culture=neutral,

    PublicKeyToken=b77a5c561934e089</ExceptionType><Message>The value could not be added to the collection, as the collection already contains an item of the same type:

    'System.ServiceModel.Description.UseRequestHeadersForMetadataAddressBehavior'. This collection only supports one instance of each type.

    Parameter name: item</Message><StackTrace>   at System.Collections.Generic.KeyedByTypeCollection`1.InsertItem(Int32 index, TItem item)

      at Microsoft.Crm.Extensibility.SdkServiceEndpointBuilder.AddDefaultPorts(ServiceHost serviceHost, PortSchemeDictionary portSchemes)

      at Microsoft.Crm.Extensibility.SdkServiceEndpointBuilder.AddDefaultEndpoint(ServiceHost serviceHost, Type implementedContract)

      at Microsoft.Crm.Extensibility.SdkServiceEndpointBuilder.BuildEndpoints(ServiceHost serviceHost, Type implementedContract, Func`1 messageInspectorFactory)

      at Microsoft.Crm.Extensibility.SdkServiceHost.InitializeRuntime()

      at System.ServiceModel.ServiceHostBase.OnOpen(TimeSpan timeout)

      at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)

      at System.ServiceModel.ServiceHostingEnvironment.HostingManager.ActivateService(ServiceActivationInfo serviceActivationInfo, EventTraceActivity eventTraceActivity)

      at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)

      at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath, EventTraceActivity eventTraceActivity)

      at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()

      at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()

      at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequest(Object state)

      at System.ServiceModel.AspNetPartialTrustHelpers.PartialTrustInvoke(ContextCallback callback, Object state)

      at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequestWithFlow(Object state)

      at System.Runtime.IOThreadScheduler.ScheduledOverlapped.IOCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)

      at System.Runtime.Fx.IOCompletionThunk.UnhandledExceptionFrame(UInt32 error, UInt32 bytesRead, NativeOverlapped* nativeOverlapped)

      at System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)

    </StackTrace><ExceptionString>System.ArgumentException: The value could not be added to the collection, as the collection already contains an item of the same type:

    'System.ServiceModel.Description.UseRequestHeadersForMetadataAddressBehavior'. This collection only supports one instance of each type.

    Parameter name: item</ExceptionString></Exception></TraceRecord>

    can you tell me how to fix this ?

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    crm and database are on the same server.

    this is what i got from the tool:

    <TraceRecord xmlns="schemas.microsoft.com/.../TraceRecord&quot; Severity="Error">

     <TraceIdentifier>msdn.microsoft.com/.../System.ServiceModel.Diagnostics.EventLog.aspx&lt;/TraceIdentifier>

     <Description>Wrote to the EventLog.</Description>

     <AppDomain>/LM/W3SVC/2/ROOT-3-131308617483044141</AppDomain>

     <ExtendedData xmlns="schemas.microsoft.com/.../DictionaryTraceRecord&quot;>

       <CategoryID.Name>EventLogCategory</CategoryID.Name>

       <CategoryID.Value>5</CategoryID.Value>

       <InstanceID.Name>EventId</InstanceID.Name>

       <InstanceID.Value>3221356547</InstanceID.Value>

       <Value0>System.ServiceModel.ServiceHostingEnvironment+HostingManager/18870471</Value0>

       <Value1>System.ServiceModel.ServiceActivationException: The service '/AlphaSales/XRMServices/2011/Organization.svc' cannot be activated due to an exception during compilation.  The exception message is: This collection already contains an address with scheme https.  There can be at most one address per scheme in this collection. If your service is being hosted in IIS you can fix the problem by setting 'system.serviceModel/serviceHostingEnvironment/multipleSiteBindingsEnabled' to true or specifying 'system.serviceModel/serviceHostingEnvironment/baseAddressPrefixFilters'.

    Parameter name: item. ---&gt; System.ArgumentException: This collection already contains an address with scheme https.  There can be at most one address per scheme in this collection. If your service is being hosted in IIS you can fix the problem by setting 'system.serviceModel/serviceHostingEnvironment/multipleSiteBindingsEnabled' to true or specifying 'system.serviceModel/serviceHostingEnvironment/baseAddressPrefixFilters'.

    Parameter name: item

      at System.ServiceModel.UriSchemeKeyedCollection.InsertItem(Int32 index, Uri item)

      at System.Collections.Generic.SynchronizedCollection`1.Add(T item)

      at System.ServiceModel.UriSchemeKeyedCollection..ctor(Uri[] addresses)

      at System.ServiceModel.ServiceHost..ctor(Type serviceType, Uri[] baseAddresses)

      at Microsoft.Crm.Extensibility.SdkServiceHostFactory.CreateServiceHost(String constructorString, Uri[] baseAddresses)

      at System.ServiceModel.ServiceHostingEnvironment.HostingManager.CreateService(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)

      at System.ServiceModel.ServiceHostingEnvironment.HostingManager.ActivateService(ServiceActivationInfo serviceActivationInfo, EventTraceActivity eventTraceActivity)

      at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)

      --- End of inner exception stack trace ---

      at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)

      at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath, EventTraceActivity eventTraceActivity)</Value1>

     </ExtendedData>

    </TraceRecord>

    <TraceRecord xmlns="http://schemas.microsoft.com/2004/10/E2ETraceEvent/TraceRecord" Severity="Error">
    <TraceIdentifier>http://msdn.microsoft.com/de-CH/library/System.ServiceModel.Diagnostics.ThrowingException.aspx</TraceIdentifier>
    <Description>Throwing an exception.</Description>
    <AppDomain>/LM/W3SVC/2/ROOT-3-131308617483044141</AppDomain>
    <Exception>
    <ExceptionType>System.ArgumentException, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</ExceptionType>
    <Message>This collection already contains an address with scheme https. There can be at most one address per scheme in this collection. If your service is being hosted in IIS you can fix the problem by setting 'system.serviceModel/serviceHostingEnvironment/multipleSiteBindingsEnabled' to true or specifying 'system.serviceModel/serviceHostingEnvironment/baseAddressPrefixFilters'.
    Parameter name: item</Message>
    <StackTrace> at System.ServiceModel.UriSchemeKeyedCollection.InsertItem(Int32 index, Uri item)
    at System.Collections.Generic.SynchronizedCollection`1.Add(T item)
    at System.ServiceModel.UriSchemeKeyedCollection..ctor(Uri[] addresses)
    at System.ServiceModel.ServiceHost..ctor(Type serviceType, Uri[] baseAddresses)
    at Microsoft.Crm.Extensibility.SdkServiceHostFactory.CreateServiceHost(String constructorString, Uri[] baseAddresses)
    at System.ServiceModel.ServiceHostingEnvironment.HostingManager.CreateService(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)
    at System.ServiceModel.ServiceHostingEnvironment.HostingManager.ActivateService(ServiceActivationInfo serviceActivationInfo, EventTraceActivity eventTraceActivity)
    at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath, EventTraceActivity eventTraceActivity)
    at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath, EventTraceActivity eventTraceActivity)
    at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
    at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
    at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequest(Object state)
    at System.ServiceModel.AspNetPartialTrustHelpers.PartialTrustInvoke(ContextCallback callback, Object state)
    at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequestWithFlow(Object state)
    at System.Runtime.IOThreadScheduler.ScheduledOverlapped.IOCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
    at System.Runtime.Fx.IOCompletionThunk.UnhandledExceptionFrame(UInt32 error, UInt32 bytesRead, NativeOverlapped* nativeOverlapped)
    at System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)
    </StackTrace>
    <ExceptionString>System.ArgumentException: This collection already contains an address with scheme https. There can be at most one address per scheme in this collection. If your service is being hosted in IIS you can fix the problem by setting 'system.serviceModel/serviceHostingEnvironment/multipleSiteBindingsEnabled' to true or specifying 'system.serviceModel/serviceHostingEnvironment/baseAddressPrefixFilters'.
    Parameter name: item</ExceptionString>
    </Exception>
    </TraceRecord>

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    O.K., tell me a little bit more about your infrastructure. Is it "All in One" installation, or do you have several servers installed?

    Is it possible for you you take a trace using Diagnostic Tool for MS CRM?

    crmdiagtool2011.codeplex.com

    Please download also Trace Reader, it will help while analyzing.

    crmtracereader.codeplex.com

    Regards, Karan

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    good manual, but that didn't help either

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    O.K., check this out and let me know if it works:

    crmgiant.eu/.../social-pane-giving-a-generic-error-on-your-microsoft-dynamics-crm-dashboard

    Regards, Karan

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    Nope didn't help

    i also receive this error on my profile in the "Posts" section

  • Suggested answer
    Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    Hi,

    seems like that the security role for "Activity Feeds" aren't assigned to the user.

    Once assigned, it will work without an error.

    Regards, Karan

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Javascript error

    this is all i  can get right now:

    crm_2D00_javascript-error2.png

    but i already searched for the warning and tried to edit the file but it didnt help

  • saadzag Profile Picture
    saadzag 1,145 on at
    RE: Javascript error

    Hello,

    Can you translate the error message?

    thx

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,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans