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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

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

Values are not saved in RouteInventProd form in d365FO

(1) ShareShare
ReportReport
Posted on by 302

Hello All,

I have added a new real field in ProdRoute and RouteOpr table, and added the field in the RouteInventProd form, However the values are not getting saved or reseting whenever the form is closed and opened again.

I was able to see there's a class called RouteInventForm has a method which is running in the init of routeInventProd form where it is deleting the prodRoute records and again inserting as the new field is not added in the map I am not getting the value. Is there a way to achieve this?

I am facing the similar issue mentioned in the following link,

https://www.axug.com/communities/community-home/digestviewer/viewthread?MessageKey=fd996f26-6f85-4c20-902a-a3e71467745a&CommunityKey=af0dadbe-c222-4660-9d1e-a9e3416c837a&tab=digestviewer

Thanks

  • Gunjan Bhattachayya Profile Picture
    35,429 on at

    Hi Wekey,

    Did you check if the values are getting saved in SQL after you set the value and close the form?

  • Wekey Profile Picture
    302 on at

    Hello Gunjan,

    Thanks for your reply.

    Yeah I can see the newly added field is null in SQL!. However other fields has values. 

    Thanks

  • Gunjan Bhattachayya Profile Picture
    35,429 on at

    Hi Wekey,

    Please try debugging the method prodRouteDsWritePost() in class "RouteInventForm". This method is handling the update of this table.

    From a cursory look, I can say that you have to add a new field into Maps\RouteMap for this to work.

  • Wekey Profile Picture
    302 on at

    Hello Gunjan,

    You are right I have already tried to debug the same and the code is trying to delete the records from prodRoute and insert again. Unfortunately it is not possible to extend the maps to add the fields in D365fo that is where the problem begins.

    Thanks

  • Gunjan Bhattachayya Profile Picture
    35,429 on at

    Hi Wekey,

    In that case, rather than  adding a field to ProdRoute, try creating a new table for this field. You can link it based on ProdRoute\RecId. You can create an extension of the form and add the table as a data source. This way you don't need to use the map.

  • Wekey Profile Picture
    302 on at

    This aint gonna work again because the records in the prodRoute is getting deleted and inserted again everytime when the form is opened so the RecId field will be varied everytime

  • Gunjan Bhattachayya Profile Picture
    35,429 on at

    You can base it on the alternate key then (NumOprNumIdx). You will need to create the fields ProdId, OprNum and OprPriority in the new table and retrieve the value of the new field based on these values from ProdRoute.

  • Wekey Profile Picture
    302 on at

    The field value is not even getting saved when I close my form!. I checked in SQL and the field is null.

  • Gunjan Bhattachayya Profile Picture
    35,429 on at

    Did you add the new table? If you are using the field in ProdRoute, I don't see how it will be saved.

  • Wekey Profile Picture
    302 on at

    I am Yet to add a new table but I am just wondering why it is not being saved? What is the flow behind this logic?

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 Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the August Top 10 Community Leaders

These are the community rock stars!

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

#1
Martin Dráb Profile Picture

Martin Dráb 539 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 431 Super User 2026 Season 2

#3
CU-1234529-002 Profile Picture

CU-1234529-002 184

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans