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 :
Finance | Project Operations, Human Resources, ...
Answered

Remove trailing zeros

(0) ShareShare
ReportReport
Posted on by

I am pulling in a dollar amount from excel via a macro but the field in GP is pre populated with $0.00 and it just gets appended to the end. How can I remove the trailing 0s? Amount should be $118,656.33

  MoveTo field 'Purchases Amount' 
  TypeTo field 'Purchases Amount' , '«Rebate_Amount»'

pastedimage1588965832660v1.png

Categories:
I have the same question (0)
  • Verified answer
    Hokuminaria Profile Picture
    2,950 on at

    Hello Carrot,

    Thank you for posting your questions!

    As we don't support Macros in GP Support, i don't have a lot of info that i can provide. However, the Community might.

    With your Excel file, are you using decimal places or just whole numbers? With GP, when we manually type a value it, it always starts at the last decimal place. If your excel file is using decimal places, try formatting the cell to be a whole number. 

    Example:

    12345.67 would be 1234567.

    Test your macro and see if that now comes into GP as 12345.67.

    If this works, for the ones that do not have a decimal places, you would need to have those cells include the .00 and the ones with cents be 123456.

    If this does not help, hopefully the community can provide insight if they have experienced this in the past.

    I hope this helps!

    Microsoft Support Engineer | Brandon Jarrett

  • Community Member Profile Picture
    on at

    Thanks for the reply. Now it gives me a "window not active" error.

    Edit: created new batch and it worked. Thank you!

    Edit2: hmm it only works for the first transaction in the batch

    Edit3: it worked when I format the cells in excel as text. Thanks.

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 > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 687 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 535 Super User 2025 Season 2

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 403 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans