Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested answer

User cannot open a new developed form -form has ds init method-cacheAddmethod

(0) ShareShare
ReportReport
Posted on by 511

Hi All,

Greetings

Hope all are fine and safe.

A new form is created. It is based on single databasource

Table A-Master form-Added few display methods on that table(calcuting some count  from table B from other table in display method)

Created a new form-Add above table-Grid-Put display methods of that form

But got series of issues

1)The display method values BLINKS in the grid-The blinking issue get solved when I add the ds.cachaddmethod(tablemethodstr(ds,displaymethod) in the form init or ds init method

But if the above method is added-user is unable to open the form at all.When the above method gets commenetd user able to open form

How to get rid of blinking(values blink and goes off and on )issue & why the cacheaddmethod when added -the user cannot open the new form even though new role,duty,privilges to form are been given to user

2)The form when gets opened goes in mimimize sate. This is again if I comment the cacheaddmethod. If cacheaddmethod is present the form gets in maximixe mode open

What m i missing here

please help

  • Suggested answer
    nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    There is no difference with any user who has system administrator role, and you (a developer). So if it works for you in the test system but not for this other user, then perhaps the problem is not at all in your code.

    Perhaps the other user is using outdated AX client (binary version lower than in the AOS)? Please compare the Kernel version (in About version of Dynamics AX) of the other user and you. Are they same or different?

  • NDingankar22 Profile Picture
    511 on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    yes as i said..if the addcachemethod is present(not uncommented) the form when open is in minimized state.Have to manually make it maximize. Tried everythng reset, incremental CIL,AOS restart. but no luck

    Weird is in test environemnt even if system admin role is given to user and the addcachemethod is not commented(i,e presnt) user cannot open form. But I can (as i  am the developer)

  • Sergei Minozhenko Profile Picture
    23,091 on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    Hi NDingankar22,

    You said that form is minimized, have you tried to expand it manually? Have you tried to reset usage data?

  • NDingankar22 Profile Picture
    511 on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    I saw your request. There is no other code except the one I wrote in init method which i mentioned above

    Should I share the display method code written at table level?

  • nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    Earlier I asked if we could see your code. Did you notice that request? Or do you prefer to not share it? It's really hard to troubleshoot without seeing the details.

  • NDingankar22 Profile Picture
    511 on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    no its not working.

    ow to get rid of blinking issue-if I add cacheAddmethod( user cannot open form) If i uncomment the code of cacheAddmethod the  user opens form but blinking still persist on form

    How  should i get rid of the blinking method

  • nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    So is it working now?

  • NDingankar22 Profile Picture
    511 on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    Thank u both for taking time to asnwer my query

    Table A-Itemid,Item name,Item frequency, display method which takes table B and count status of created, active, Inactive

    Table B-Many item id having status as createdm ,active, inactive,date

    New form

    Datasource-Table A-Physical fields-Item id, Item name,Frequency(they dont blink), Display method-Count(Active),Cont(Inactive) etc

    On form ds init method

    wrote the following as

    TableA_ds.cacheddmethod(tablemethodstr(table A,display method) -to avoid blinking issue

  • Sergei Minozhenko Profile Picture
    23,091 on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    Hi NDingankar22,

    Usually blinking means that you have performance issues with your display method and without caching display method is re-calculated constantly.

    Are you using the same statement in init method of data source, because it looks weird (datasource is used in tableMethodStr)?

    ds.cachaddmethod(tablemethodstr(ds,displaymethod)

    should be at least

    ds.cachaddmethod(tableMethodStr(table, displaymethod))

  • nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: User cannot open a new developed form -form has ds init method-cacheAddmethod

    As usual, it's good if you can share your code.

    Does this form /grid have any normal physical fields from the same table? Do they work as expected?

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,888 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,772 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Product updates

Dynamics 365 release plans