Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Suggested answer

Disable create line in purchase order lines x++

(0) ShareShare
ReportReport
Posted on by 163

 want to disable create line automatic in purchase order lines I tried to make insert if empty property to No but it was already No . 

When clicking on new on purchase order form or purchase order for service and create new po it created lines in purchase order lines automatic with data in (create purchase order )form  I want to disable it .

which method in (purchasecreateorder )form make this ? Or How can I do this ?

Screenshot-_2800_250_2900_.png

Screenshot-_2800_251_2900_.png

  • Mohit Rampal Profile Picture
    Mohit Rampal 12,552 Super User 2024 Season 1 on at
    RE: Disable create line in purchase order lines x++

    Hi Menna, PurchLine record will not be inserted but will be initialized so you will see an empty line with Line number. I believe the below code in linkActive method in PurchLine datasource of PurchTable form is triggering the code to create empty line. I debugged the code and bypass this line of code and empty line was not created.

    pastedimage1684407712705v1.png

  • Menna Allah Ahmed Profile Picture
    Menna Allah Ahmed 163 on at
    RE: Disable create line in purchase order lines x++

    No record is not created , values set by initValue method , what should I do to make this grid empty ?

  • GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: Disable create line in purchase order lines x++

    Also, if the record is created in the PurchLine Table. You must delete the record. So try to delete the record while creating of purchase order. Override clicked method of the creation form ok button and add code to delete a line record based on the header record.

    Thanks,

    Girish S.

  • Suggested answer
    GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: Disable create line in purchase order lines x++

    Hi,

    I think record is created in the PurchLine table. Just open the PurchLine in table browser and see if there is any record exists agains the header.

    Thanks,

    Girish S.

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

Announcing Our 2025 Season 1 Super Users!

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

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,965 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,836 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans