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 AX (Archived)

Records in form not saved when no changes are made

(0) ShareShare
ReportReport
Posted on by 107

Hi All,

I have a simple form with a grid and an action pane with a "New" button. When i click the new button, a line in the grid is added. When i make no changes to the record and i click the new button again, a new line is added. I can keep doing this and more and more lines are being added. When i close the form and i open it again, no records are shown.

Validate write, insert, ... methods are not being called.

It seems that when i make no changes, the records are shown but not actually "created" and thus not saved/validated. I see the same thing happen on standard Ax forms as well, for example on the free text invoice templates form.

Is there a way to prevent this and "force" a save? Maybe a property somewhere?

*This post is locked for comments

I have the same question (0)
  • axk Profile Picture
    925 on at

    Check if you properly set data sources for "New" button, groups and grid. Maybe records are created, but not visible in the form. Check if they were inserted into table.

  • Anton Venter Profile Picture
    20,656 Super User 2026 Season 1 on at

    It should save the records without having to do anything extra. Is it not a license issue where AX has gone into demo mode?

  • BuBbA Profile Picture
    107 on at

    They are all fine, when i change the record before clicking new, the records are validated and inserted. The problem is when i leave the record blank.

    Same problem with, for example, the free text invoice templates form. This is a default form, standard ax, no customizations. This form shows the same behaviour.

  • Verified answer
    axk Profile Picture
    925 on at

    Okay, I did not understand what your problem actually is.

    If you are leaving a record, data source's leaveRecord() method is called with default parameter _forceUpdate = false. You can change it to true and then, your records will be saved, even if no changes were made.

    Check if it works for you.

  • BuBbA Profile Picture
    107 on at

    Yep, that's exactly what i needed! Thanks!

  • Anton Venter Profile Picture
    20,656 Super User 2026 Season 1 on at

    You wrote that you see this in standard forms too, or is it just in your form?

  • BuBbA Profile Picture
    107 on at

    Yes, you see the same behaviour in standard forms as well. Look at the following forms for example:

    - CustGroup

    - CustBillingCode

    - MarkupTable

    ...

    Since it's the standard way of Ax, it's probably gonna be like that on almost all the forms. I find it a very odd way of working.

  • Suggested answer
    PA-22040759-0 Profile Picture
    6,194 on at

    In the LedgerJournalTable form you can see coded added to prevent this behavior. The code is in the leave method of the LedgerJournalTable datasource.

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 AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Alexey Lekanov Profile Picture

Alexey Lekanov 2

#2
Henrik Nordlöf Profile Picture

Henrik Nordlöf 2 User Group Leader

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans