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

Ax7, "Invalid sort field" message in Custom Lookup Form

(0) ShareShare
ReportReport
Posted on by 260

Hi,

I have built a custom lookup form and used it on the Form Help property in an extended data type. Everything works ok but only when the field where I make the lookup is empty. When the field has already a value and I try to select a new value I get the error "Invalid sort field". 

Does anyone have an idea what could be?

Thanks

*This post is locked for comments

I have the same question (0)
  • PedroSpain Profile Picture
    260 on at

    By the way I found it:

    It seems that in Ax7 we need also to edit the rund method in the lookup form with something like this (From AssetBookLookup)

    public void run()
    {
        FormStringControl callingControl = SysTableLookup::getCallerStringControl(element.args());
        boolean filterLookup;
        ;
     
        filterLookup = SysTableLookup::FilterLookupPreRun(callingControl, assetBookTable_BookId, assetBookTable_ds);
     
        super();
     
        SysTableLookup::FilterLookupPostRun(filterLookup, callingControl.text(), assetBookTable_BookId, assetBookTable_ds);
    }

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
CP04-islander Profile Picture

CP04-islander 21

#2
dekion Profile Picture

dekion 4

#2
Virginia99 Profile Picture

Virginia99 4

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans