Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Forums / Finance forum / BPWarningDisplayMethod...
Finance forum
Suggested answer

BPWarningDisplayMethodUpdateUnpredictable: The display method in Form may not update as expected

Posted on by 234
Hi,

I got this BP warning:
BPWarningDisplayMethodUpdateUnpredictable: The display method 'test' in form '$testForm' may not update as expected

i'm getting the BP warning on the 2 display methods test() and test1()
[Form]
public class TestForm extends FormRun
{
    ClassTestContract   classTest;
    

    /// <summary>
    /// init
    /// </summary>
    public void init()
    {
        classAContract classA;

        super();

        classA = element.args().parmobject() as classAContract;

        classTest = classA.parmClassTestContract();
    }

    public display boolean test()
    {
      return classTest.parmX().parmY()? true : false;
    }

    public display boolean test1()
    {
        return classTest.parmZ().parmY();
    }

}

How to fix it?
  • Martin Dráb Profile Picture
    Martin Dráb 225,588 Super User on at
    BPWarningDisplayMethodUpdateUnpredictable: The display method in Form may not update as expected
    The warning tells you that you may expect display values being updated when parmX(), parmY() or parmZ() starts returning a different value, but it won't happen, because you haven't implemented such a logic. The values will be obtained just once. The system can't say whether it's the behaviour you want or not.
  • CU04051814-0 Profile Picture
    CU04051814-0 234 on at
    BPWarningDisplayMethodUpdateUnpredictable: The display method in Form may not update as expected
    Hi Andre,

    do you mean to set the value of the unbound control in the init method of the form??

    and normally if there is a display method, then it should be put in the form datasource instead of form?
  • Suggested answer
    André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 287,986 Super User on at
    BPWarningDisplayMethodUpdateUnpredictable: The display method in Form may not update as expected
    Hi,
     
    You get this warning in case the display methods are created on the form instead of a form data source. In case the information is retrieved only once when opening the form, you can better use unbound controls and fill the values by setting a value for these controls.

Helpful resources

Quick Links

Replay now available! Dynamics 365 Community Call (CRM Edition)

Catch up on the first D365 Community Call held on 7/10

Community Spotlight of the Month

Kudos to Saurav Dhyani!

Congratulations to the June Top 10 community leaders!

These stars go above and beyond . . .

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 287,986 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 225,588 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans