web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Dynamics 365 Community / Forums / Finance forum / What is the alternativ...
Finance forum

What is the alternative for getDataRow?

(0) ShareShare
ReportReport
Posted on by 306,692 Super User 2026 Season 2

Hi all,

While migrating a solution from AX2012 to Dynamics 365, we now get a best practice warning that the getDataRow Data Source method has been depreciated. This is also mentioned on the next page: https://docs.microsoft.com/en-us/dynamics365/unified-operations/dev-itpro/migration-upgrade/deprecated-apis

What is the alternative? Standard coding from Microsoft is still using it in the class TradeLineNumberManager. We have a similar coding to correct.

protected boolean isLastLine(FormDataSource _formDataSource)
{
    return _formDataSource.getDataRow(_formDataSource.getPosition()+1) == null;
}

As alternative, we can try to find the highest line number with coding in the table and compare it with the current line number. But is there an alternative data source method?

I have the same question (0)
  • Sukrut Parab Profile Picture
    71,741 Moderator on at

    Hi Andre ,

    As far as I see there is no alternate method  and old method is not deprecated  till now . If you are thinking that at some point its going to be deprecated better to go with custom logic.

  • André Arnaud de Calavon Profile Picture
    306,692 Super User 2026 Season 2 on at

    Thanks Sukrut,

    On the link, I shared, there are alternative procedures for many depreciated API's. Not for this one. We noticed that it is a warning only, but to be ready for the future, we usually try to get rid of all best practice warnings. As it is listed as depreciated API, for sure, a future platform version will not support this method anymore.

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard > Finance

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans