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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

force submit on a read-only field

(0) ShareShare
ReportReport
Posted on by 2,665

Hi,

I have been troubleshooting an issue and found this article to be helpful.

http://blogs.msdn.com/b/arpita/archive/2012/02/19/microsoft-dynamics-crm-2011-force-submit-on-a-disabled-field-or-read-only-field.aspx

My problem is, this issue is not happening to all the users but a single person. So I am confused and need your help in troubleshooting.

On form load I have a script which autopopulates the current user's county based on the user's id.

It runs only for the new forms and not for the existing records. Everything was working fine except for a user whose records have county field with null values. For some reason the county does not get saved into the database.

And yes, the county field is a read-only field. As the above article says, we need to force the submit. Why do you think it works for other users and not for this particular user?

Someone please help me. Thanks in advance.

*This post is locked for comments

I have the same question (0)
  • Mahendar Pal Profile Picture
    45,095 on at

    Hello,

    First thing you have to use force submit if your field is readonly, and you can try to debug your code (assuming you have java script there??) so you can check what is the issue there.

    Thanks

  • Verified answer
    Royal King Profile Picture
    27,686 on at

    Place a same field somewhere in the same form ( You can add same field more than once in a form)  and set default visible to false with read/write that way even though visible field is read-only other field is read/write so system will automatically save when value is populated.

  • Suggested answer
    Neil Parkhurst Profile Picture
    10,727 User Group Leader on at

    From what you describe the county field saves correctly (using forcesubmit) for all users except this one guy with a null county.

    On that basis there is probably nothing wrong with your forcesubmit code. Or all users would be impacted.

    Where have you located the forcesubmit code, I am wondering if it isn't triggered for the null country as that value isn't changing. Maybe try forcesubmit event in the onload event and also try to prove your onsave is triggered with the null county!

    If you set a county for this user and the problem goes away then it may point to this type of issue.

  • crmprogrammer2013 Profile Picture
    2,665 on at

    It worked. Thank you.

    May I know, why you suggested this route instead of forcesubmit??

    Thanks much again.

  • Aileen Gusni Profile Picture
    44,524 on at

    Hi Roxanna

    Does it read only with the padlock or key?

    Thanks

  • Royal King Profile Picture
    27,686 on at

    There is no need of javascript if you go with adding same field twice in the form visible field  read only and non visible field read/write.

  • crmprogrammer2013 Profile Picture
    2,665 on at

    Thanks Chitra.. I thought it worked. But it failed to save for some records and when I opened those records.. I am seeing 'Unsaved Changes' in the bottom and only after clicking 'Save' the value is getting saved!

    I can't really find a similarity between the ones that worked and the others that didn't work.

    Please look into this. Thanks again.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
JS-09031509-0 Profile Picture

JS-09031509-0 3

#2
AS-17030037-0 Profile Picture

AS-17030037-0 2

#2
Mark Eckert Profile Picture

Mark Eckert 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans