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

How to refresh form in x++

(0) ShareShare
ReportReport
Posted on by

Hi,

How to refresh a current form in x++,(not a caller form)

I write a code for update in form button's clicked method.

after that I wrote code like this

datasource.reread();

datasource.research(true);

If I try to update 2 records value, Last updated records only show in form grid, once refresh the form grid show all updated records..

Give a suggestion for How to refresh the form in x++?

Thanks in advance

I have the same question (0)
  • Verified answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    No code needed, just set property "Auto refresh data" of the button to Yes.

    Alternatively via x you can use

    datasource.refresh();
    datasource.research(true);

  • Verified answer
    WillWU Profile Picture
    22,363 on at

    Hi Ashokkumar,

    And you could check the following blog to figure out refresh, reread, research, executeQuery method:

    community.dynamics.com/.../tutorial-58-refresh-reread-research-executequery-which-one-to-use-63

  • Verified answer
    ergun sahin Profile Picture
    8,826 Moderator on at

    I think you are updating more than one record with the button(it is correct?). What is the SaveRecord property on the button?

    If you don't mind losing values like filters/position, you can use ExecuteQuery.

    community.dynamics.com/.../tutorial-58-refresh-reread-research-executequery-which-one-to-use-63

  • Community Member Profile Picture
    on at

    Hi, Thanks for your reply

  • Community Member Profile Picture
    on at

    Thanks for your response

  • Community Member Profile Picture
    on at

    Thanks for your response

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

#1
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 616

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 460 Super User 2026 Season 1

#3
Syed Haris Shah Profile Picture

Syed Haris Shah 331 Super User 2026 Season 1

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans