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

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Make sub grid mandatory

(0) ShareShare
ReportReport
Posted on by 50

I have a subgrid on quote i want make that sub grid mandatory (if it doesn't contain any records) on clicking of activate quote ribbon button? through java script. Please help me thank in advance.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Community Member Profile Picture
    on at
    RE: Make sub grid mandatory

    I assume that you mean that you want to check that at least one record is entered in the quote sub-grid. Are you using the standard quote details entity in the subgrid or are you using a custom related entity to the quote? Also, will the line items always have a value? Could you have line items that have a zero value/amount?

    If you are using the standard quote detail entity, then you could create real-time workflow that checks that there is a value in the quote subtotal (which is the aggregate of the quote detail lines). The real-time workflow can prevent the quote from being activated if there is not subtotal.

    I hope this response helps you.

    André

  • Verified answer
    flavia.takushi Profile Picture
    on at
    RE: Make sub grid mandatory

    Hi,

    Maybe you could use getTotalRecordCount javascript method to retrieve the number of records from a subgrid, then make the validation you want.

    Please check the link below for more information:

    msdn.microsoft.com/.../dn932126.aspx

  • SuneelReddy Profile Picture
    50 on at
    RE: Make sub grid mandatory

    hi, thanks AndreDalen,

    That is on line editable HTML  grid

  • SuneelReddy Profile Picture
    50 on at
    RE: Make sub grid mandatory

    Thanks Flavia Takushi

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
HR-09070029-0 Profile Picture

HR-09070029-0 2

#2
ED-30091530-0 Profile Picture

ED-30091530-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans