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)

Get the Form Values and Save in Ax table

(0) ShareShare
ReportReport
Posted on by 140

Dear All,

I am very new to Ax and just started the programming on Ax,

Can any one help me and do a favor in knowing me to save the Form Control data into Ax table

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Ajit Profile Picture
    8,788 on at

    Create a form and use a table as a data source in that form and when you use columns from that data source and enter values, it will save records in that table. You will get plenty examples on web.

  • SIDDI Profile Picture
    140 on at

    Thanks for your swift reposne,

    I am trying to insert  the values on "Button click event" ,When I pass static values it's working fine .
    But when I am trying to save the form control values through "Button Click event" then I am unable to do it.

    Can you help me how can I do this on button click event

  • SIDDI Profile Picture
    140 on at

    why don't you provide the sample code on button click event

  • Suggested answer
    Vilmos Kintera Profile Picture
    46,149 on at

    He has AX 2012 tags, so pasting D365fF&O details is not going to be helpful.

    SAM: why are you trying to implement something, which is already there. AX saves information which you have entered in a table/field-bound control on a form, if:

    - you press the Save button on the toolbar (if you have enabled those)

    - you press Control + S

    - you navigate away from the record

    - you close the form with the Window X button, or Close button

    Implementing a save functionality for a button does not sound like Best practice for me at all.

  • SIDDI Profile Picture
    140 on at

    Dear ,

    I have custom validations to take care before saving the information into table and also needs to take action on other tables and inform the user a message on button click.

    If i use the button command I will certainly save the information,But I can't go through the custom validation which need to take my project furhter .

  • Suggested answer
    Ajit Profile Picture
    8,788 on at

    You can override validateWrite method in order to validate and then you can write a method on form to send message to user if validateWrite returns false.

  • Suggested answer
    Vilmos Kintera Profile Picture
    46,149 on at

    Again, for custom validations you have standard methods which could be overridden.

    Placing custom code on form buttons involving database operations is bad practice, which would fail the code review within my team.

    You should put the least amount of code on client-side (forms, buttons). That is why you should do as Ajit has suggested, overriding the methods for validation on the Tables involved.

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!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the March Top 10 Community Leaders

These are the community rock 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