web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Cannot Save Account in CRM 2011 using Firefox

(0) ShareShare
ReportReport
Posted on by 1,110

Hi,

     I am running an organizationally hosted instance of Dynamics 2011.   I find that in Firefox 22.0  it does not allow me to save an account (old or new).  The only message I receive in the browser is:

Error

An error has occurred.

     The event log on the server reads as follows:

NT AUTHORITY\SYSTEM
   FormatException
   Input string was not in a correct format. at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal)...

    Any thoughts or suggestions?  IE and Chrome work fine for now, however, I fear this issue may crop up in those browsers as well since everything worked in Firefox just a few days ago.  Thank you.

*This post is locked for comments

I have the same question (0)
  • Farhan Syed Profile Picture
    1,156 on at

    Hi Wink2010,

    Are you on the latest Roll Up ?

    Have you tried running the trace on the server while trying the same 'save' routine from the client?

    The CRM Diagnostic Tool : crmdiagtool2011.codeplex.com

    You may end up getting a detailed error message using this.

  • wink2010 Profile Picture
    1,110 on at

    I used the tool you suggested.  This is the result I received.  It is still very vague.  The log file produced by the tool is basically the same.

    Server Error in '/' Application.


    Input string was not in a correct format.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.FormatException: Input string was not in a correct format.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


    Stack Trace:

     

    [FormatException: Input string was not in a correct format.]

     

       System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +12636309

     

       System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +224

     

       Microsoft.Crm.Application.Platform.EntityProxy.SetPicklistData(XmlNode node, AttributeMetadata attributeMetadata) +194

     

       Microsoft.Crm.Application.Platform.EntityProxy.SetData(XmlNode entityElement) +711

     

       Microsoft.Crm.Application.Forms.EndUserForm.RetrieveParametersForEventDefault() +199

     

       Microsoft.Crm.Application.Forms.EndUserForm.Initialize(Entity entity) +52

     

       Microsoft.Crm.Application.Forms.CustomizableForm.Execute(Entity entity, FormDescriptor fd) +216

     

       Microsoft.Crm.Application.Components.PageHandlers.AccountRecordPageHandler.ConfigureFormHandler() +347

     

       Microsoft.Crm.Application.Components.PageHandlers.RecordPageHandler.ConfigureFormWrapper() +47

     

       Microsoft.Crm.Application.Components.Utility.GenericEventProcessor.RaiseEvent(String eventName) +230

     

       Microsoft.Crm.Application.Controls.PageManager.OnPreRender(EventArgs e) +259

     

       System.Web.UI.Control.PreRenderRecursiveInternal() +113

     

       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4201

     

  • Farhan Syed Profile Picture
    1,156 on at

    Thanks for the file. Has there been any j Script customizations done on the account form ?

  • Suggested answer
    Farhan Syed Profile Picture
    1,156 on at

    Hi Wink2010, please update the thread. Are there any customizations (read jScript) done on your form ?

    By the way, this is what I tried on a sandbox environment and production environment while accessing CRM.

    Did a couple of save's on customized CRM forms and the default form before and after installing the Firefox 22.version and it worked fine. (no need of iisreset nor any browser refresh). Absoutely fine.

    Could you try if in case you have some add-ins set up in your browser ? Try replicating the same exercise of save on a different client

  • wink2010 Profile Picture
    1,110 on at

    Hi Farhan.

          I wanted to make sure I had solid information before I posted again.  

         My testing just showed me the problem is with the javascript (code is below) just moments ago.  I have not had a chance to actually look at the code, but when I find the problem, I will post again.  I discovered this to be the source of the issue be deactivating this script from the form.  When the script is deactivated the account saves in Firefox.

    var changeAccountStatus = function(){

    var sel = document.getElementById("customertypecode");

    var selectedText = sel.options[sel.selectedIndex].text;

    var optionsetControl = Xrm.Page.ui.controls.get("accountcategorycode");

    var options = optionsetControl.getAttribute().getOptions();

    if (selectedText  == "Partner"){

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[6]);

    }

    else if (selectedText  == "Customer"){

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[4]);

    optionsetControl.addOption(options[5]);

    }

    else if (selectedText  == "Prospect"){

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[1]);

    optionsetControl.addOption(options[2]);

    optionsetControl.addOption(options[3]);

    }

    else{

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[0]);

    }

    };

    var changeAccountStatusLoad = function(){

    var optionsetControl = Xrm.Page.ui.controls.get("accountcategorycode");

    var options = optionsetControl.getAttribute().getOptions();

    var accountStatus = document.getElementById("accountcategorycode");

    var accountStatusText = "";

    if (accountStatus.selectedIndex != -1){

    accountStatusText = accountStatus.options[accountStatus.selectedIndex].text;

    }

    if (accountStatusText == "Partner"){

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[6]);

    optionsetControl.getAttribute().setValue(options[6].value);

    }

    else if (accountStatusText.indexOf("Customer") != -1){

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[4]);

    optionsetControl.addOption(options[5]);

    if (accountStatusText.indexOf("Active") != -1){

    optionsetControl.getAttribute().setValue(options[4].value);

    }else{

    optionsetControl.getAttribute().setValue(options[5].value);

    }

    }

    else if (accountStatusText.indexOf("Prospect") != -1){

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[1]);

    optionsetControl.addOption(options[2]);

    optionsetControl.addOption(options[3]);

    if (accountStatusText.indexOf("Active") != -1){

    optionsetControl.getAttribute().setValue(options[3].value);

    }else if (accountStatusText.indexOf("Disqualified") != -1){

    optionsetControl.getAttribute().setValue(options[1].value);

    }else{

    optionsetControl.getAttribute().setValue(options[2].value);

    }

    }

    else{

    optionsetControl.clearOptions();

    optionsetControl.addOption(options[0]);

    optionsetControl.getAttribute().setValue(options[0].value);

    }

    };

  • wink2010 Profile Picture
    1,110 on at

    UPDATE:

        The problem lies with the very last line.  The only function being called is var changeAccountStatusLoad = function().    The last line is optionsetControl.getAttribute().setValue(options[0].value);   Something is wrong with it.

  • wink2010 Profile Picture
    1,110 on at

    UPDATE:

        That last line of JS sets the Account Status dropdown list.  In every other browser there is a value of "NA" for that line to access.  "NA" is not present in Firefox, but the list does render as though there are two options.  The first option is always blank, but the second option should be "NA".  In Firefox both options are blank.

  • wink2010 Profile Picture
    1,110 on at

    UPDATE:

          The problem may stem from something else I have noticed.  The Account Status dropdown should have several options listed.  It, in fact, does have options listed when its properties are viewed through the customization form.  These options are not listed at all in Firefox and only "NA" is listed in other browsers.

  • Farhan Syed Profile Picture
    1,156 on at

    Thanks for those updates! Whats happening with Firefox here ?! The good thing here is that you have two backup options (IE and Chrome) for you to continue your work, but its good these cases are getting raised....

    I have personally not come across this, but what I'd try before digging down further would be to remove and add the field in the account form (do this exercise in Firefox) and republish.

    Is the status field a global option set or you have customized it only for the account form ?

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans