Change in Currency code is not in log entry

tvandongen
Member Posts: 78
We have sometimes that on the customer and contact card the currency code is deleted. We have the change log activated for all fields (customer, contact and vendor tables), but this change is not registered.
I've done some tests and if I change de currency code on de contact card it is also changed on the customer card. When I then check the change log there is one entry for the change of the contact card, but not for the change of the customer card.
I also tried to put some extra code on the customer card, but this code is not executed when it is changed through the contact card.
Does anybody know how I can find out which function is responsible for the unwanted change or how I can enable the logging for this.
I've done some tests and if I change de currency code on de contact card it is also changed on the customer card. When I then check the change log there is one entry for the change of the contact card, but not for the change of the customer card.
I also tried to put some extra code on the customer card, but this code is not executed when it is changed through the contact card.
Does anybody know how I can find out which function is responsible for the unwanted change or how I can enable the logging for this.
0
Answers
-
-
Kine,
I've checked them, but that are the standard navsion functions. In these functions there is only the code:WITH Cust DO BEGIN GET(ContBusRel."No."); NoSerie := "No. Series"; TRANSFERFIELDS(Cont); "No." := ContBusRel."No."; "No. Series" := NoSerie; MODIFY; END;
So maybe the transferfields is creating this issue, but how can I log that ?0 -
Change log is logging only changes made by users. If the change is made by code, it is not logged (as you experienced). Solution is to add code calling the Change log functionality. You can search this forum for that, or look into the codeunit 1, function OnGlobalModify what is called there and call same code from the appropriate point in the process...0
-
Thanks Kine,
I've now modified codeunit 5055 intoWITH Cust DO BEGIN GET(ContBusRel."No."); NoSerie := "No. Series"; xRecRef.GETTABLE(Cust); TRANSFERFIELDS(Cont); "No." := ContBusRel."No."; "No. Series" := NoSerie; MODIFY; RecRef.GETTABLE(Cust); ChangeLogMgt.LogModification(RecRef,xRecRef); END;
and this resulted in the correct logging.0 -
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions