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

Form grid to show from the last record

(0) ShareShare
ReportReport
Posted on by 596
Hi guys,
 
In my custom form - data source, I have specified the /Start position/ to be Last ->
 
But when I open this form, it won't show from the last record (newest) ->
 
May I know how to make the display as I wanted to ?
Thanks
 
I have the same question (0)
  • Verified answer
    GirishS Profile Picture
    27,843 Moderator on at
    Hi Voltes,
     
    Start position property determines whether to keep the cursor in first or last record as a current record. Which means it will set the cursor to last record if you set as Last. If you set its as First, it will move the cursor to first record.
    If you want to display the latest record first, you need to add the code on the executeQuery method of the DataSource.
    Refer to the below code.
    DataSourceName_ds.queryBuildDataSource().addSortField(fieldNum(TableName, RecId),SortOrder::Descending);
     
    Thanks,
    Girish S.
  • Suggested answer
    Mohit Rampal Profile Picture
    12,573 Moderator on at
    Hi Voltes, In addition, You can check this article
     
    https://rahulmsdax.blogspot.com/2018/12/sorting-data-in-form-datasource-in.html

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 April 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 608

#2
André Arnaud de Calavon Profile Picture

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

#3
CP04-islander Profile Picture

CP04-islander 430

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans