Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

i want to edit field in Item Ledger Entry

Posted on by 90

I am trying to edit new field ( which I added ) in Item Ledger Entry, I tried creating new code unit same Cust Entry-Edit and modifying only the new field but it did not work 
can anyone help me with that 

  • muaz deyab Profile Picture
    muaz deyab 90 on at
    RE: i want to edit field in Item Ledger Entry

    Is is possible to be a problem in the license ?

  • muaz deyab Profile Picture
    muaz deyab 90 on at
    RE: i want to edit field in Item Ledger Entry

    Thanks for ur answer. I already did everything the same as cust ledger entry but still did not work  

    this is the code i wrote in the code unit 

    OnRun(VAR Rec : Record "Item Ledger Entry")

    ItemLedgEntry := Rec;
    ItemLedgEntry.LOCKTABLE;
    ItemLedgEntry.FIND;

    IF ItemLedgEntry.Open THEN BEGIN


    ItemLedgEntry."Parent Item No":="Parent Item No";
    END;

    ModifyItemLedgerEntry(ItemLedgEntry,Rec);
    ItemLedgEntry.TESTFIELD("Entry No.","Entry No.");
    ItemLedgEntry.MODIFY;
    Rec := ItemLedgEntry;

    and i gave it modification permission for ILE

  • Suggested answer
    YUN ZHU Profile Picture
    YUN ZHU 73,647 Super User 2024 Season 2 on at
    RE: i want to edit field in Item Ledger Entry

    Hi, The method shared by Inge should be work well.

    I think you can refer to the standard code of Customer Ledger Entries, there are some fields that can be modified.

    pastedimage1641943654574v1.png

    Hope this will help.

    Thanks.

    ZHU

  • muaz deyab Profile Picture
    muaz deyab 90 on at
    RE: i want to edit field in Item Ledger Entry

    Thank you for your answer, I really appreciate it . I already did this. I created code unit with modification permission ( same as Cust ledg-Edit CU) and add the field I wanted to edit but I can not edit the field in ILE ( the value does not even change). I guess the code unite is working fine but the problem is in the ILE, how i can modify the field?

  • Suggested answer
    Inge M. Bruvik Profile Picture
    Inge M. Bruvik 32,748 Super User 2024 Season 1 on at
    RE: i want to edit field in Item Ledger Entry

    The Item Ledger Entry table is read-only by default. So if you have any objects that needs to edit them. The object that is editing it (page, report or codeunit) needs to be granted a specific permission to to edit the records.

    https://navisionary.com/?p=359

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans