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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

Filter inventSum datasource on physicalInventCalculated method

(0) ShareShare
ReportReport
Posted on by 240

I have a form where InventSum table is being used as one of the data sources. I need to remove the lines from the form where InventSum.physcialInventCalculated() is 0.

The method has the following calculation in it:

display public InventQtyPhysicalOnhand physicalInventCalculated()
{
     return this.PostedQty + this.Received - this.Deducted + this.Registered - this.Picked;

So in other words if the above-mentioned calculation equals 0 then that line of InventSum should not be displayed in the form.

Is there any way to achieve this functionality through form code?

I have the same question (0)
  • André Arnaud de Calavon Profile Picture
    301,082 Super User 2025 Season 2 on at

    Hi Hassan,

    You posted the question in the Dynamics 365 Finance forum and also used the tag "AX2012". What version are you using?

  • Hassan Akhtar Khan Profile Picture
    240 on at

    Oh sorry, posted in wrong forum.. It is related to AX 2012.

    Is there any way to change the forum or I should ask the question again in different forum?

  • André Arnaud de Calavon Profile Picture
    301,082 Super User 2025 Season 2 on at

    I have moved it for you now.

  • André Arnaud de Calavon Profile Picture
    301,082 Super User 2025 Season 2 on at

    Hi Hassan,

    On the Dimension display settings (button usually on all forms using data based on InventDim), there is an option to set quantities <> 0.

  • Hassan Akhtar Khan Profile Picture
    240 on at

    Thanks Andre for your help.

    As for your answer, I need to apply filter on the basis of some custom control, besides there is no such option available in the Dimension display settings of this form.

  • André Arnaud de Calavon Profile Picture
    301,082 Super User 2025 Season 2 on at

    Hi Hassan,

    Which exact form do you want to apply the filter or is it a custom form?

  • Hassan Akhtar Khan Profile Picture
    240 on at

    Hi Andre,

    Its "Shelf advice as of date" form in inventory management. (AOT name: PdsInventBatchShelfAdvice)

    BTW can we add 'quantity <> 0' option if it is not already available?

  • Verified answer
    Hassan Akhtar Khan Profile Picture
    240 on at

    I have achieved the output through following steps:

    1. Created a view for InventSum table.
    2. Added a computed column 'physicalInventCalculated' in the view and implement the same calculation in that method as the display method with the same name in InventSum table.
    3. Joined the InventSumView with InventSum table datasource in my form and applied the filter on the physicalInventCalculated field of the view.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 503 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 434 Super User 2025 Season 2

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 278 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans