Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Remove comma from specific whole number field

(0) ShareShare
ReportReport
Posted on by

I have tried using the below suggestion :https://stackoverflow.com/questions/30161583/crm-2013-to-remove-comma-from-whole-number-field but the onchange event is not working. kindly let me know if there are any other options

*This post is locked for comments

  • Suggested answer
    Jagannath Profile Picture
    545 on at
    RE: Remove comma from specific whole number field

    Hi Divya,

    Check with different different browsers.

    Sometimes may be browser issue.

    Thanks

  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at
    RE: Remove comma from specific whole number field

    Hi Divya,

    I think this is only the supported approach by which you can do this.

    Here is some step you can also  follow below steps .

    > let's say you have two field new_wholenumber and new_text in your form

    > Make display none by double clicking the field new_wholenumber.

    > Register below function on change of the text field which enable to any change in the text to assign to the whole Number.

    function OnchangeTextField(){

      var stringValue = Xrm.Page.getAttribute("new_text").getValue();

    Xrm.Page.getAttribute("new_wholenumber").setValue(stringValue);

    }

    >  Dynamics 365 support onkeypress so using this method you can  Restrict only numbers in the new_text field.

    Here is the reference you need to just add the function on the onload method.

    mahadeomatre.blogspot.in/.../keypress-methods-in-ms-crm-2016.html

    Hope this helps

  • ScottDurow Profile Picture
    19 on at
    RE: Remove comma from specific whole number field

    Hi,

    Are you using the text field approach? So copying the value from the number field to the text field and back?

    If so could you post your code? Also make sure you register the on change event in the form attribute and publish the changes.

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

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Kudos to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Microsoft Dynamics CRM (Archived)

#1
Mohamed Amine Mahmoudi Profile Picture

Mohamed Amine Mahmoudi 83 Super User 2025 Season 1

#2
Community Member Profile Picture

Community Member 52

#3
Victor Onyebuchi Profile Picture

Victor Onyebuchi 6

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans