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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Set default value of a checkbox

(0) ShareShare
ReportReport
Posted on by

Hello there,

In the PurchReqLine details, there is a checkbox for 'Accept partial delivery'. By default this is set to false. How would I modify it to true by default.

I tried setting the value to 1 in AOT but it didn't work.

I also tried inserting a line in the run() method of the main form (PurchReqTable form) methods as: LineComplete.checked(true);

That didn't work either.

Any help is appreciated.

thank you.

 

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Gertjan Profile Picture
    1,200 on at

    You should add the initialization in the initValue method of the purchreqline table or on the initvalue of the datasource in the form or dataset. In this method you can define the default value. You will need a (small) modification for this.

    If the value is not preserved when saving the record (insert or update) it means that after the initialization of the line somewhere in code the value is changed. But please first testwith the initValue methods mentioned.

    Can you verify if this worked for you?

  • Community Member Profile Picture
    on at

    Hi Gertjan,

    I have tried editing the initValue method of the purchreqline table and even the run method of the purchrqetable form. to no avail.

    This request has been resent from Purchasing team. is there anything I'm missing?

  • Verified answer
    Community Member Profile Picture
    on at

    I have figured out my issue. It's now working fine.

    I added the line below to the datasource table's initvalue method.

    this.LineComplete= true

    thank you

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 July Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans