Welcome to Portal

?Unknown\pull-down

Welcome to Zoho Cares

Bienvenido a Soporte de Zoho

Search our knowledge base, ask the community or submit a request.

Are you making the most of your subforms in Zoho CRM? Do you wish you could automate subform interactions and enhance user experience effortlessly? What if you had Client APIs and events specifically designed for subforms?

We are thrilled to introduce one of the most anticipated Client Script Updates: Subform Events and Subform-specific Client APIs in Client Script!

 Subform events are triggered from user actions, such as adding or deleting rows or updating data in subform. These events allow you to run Client scripts for validation, automation, or dynamic updates. By leveraging Subform Events, you gain precise control over subform behavior.  

This empowers you to achieve advanced interactivity, streamline workflows, enhance user interactions, and deliver exceptional user experiences.

Subform Events

  • onCellChange 

  • onRowAdd

  • onRowDelete

  • beforeRowDelete

  • beforeRowUpdate (Applicable only for Detail Pages)

Supported Pages

  • Standard - Create/Edit/Clone Pages, Detail page

  • Canvas - Create/Edit/Clone Pages, Detail page

  • Wizard - Create/Edit Pages

 

Available Client APIs


Notes  Note :   The setValue method for a subform row and cell on the Detail Pages will only work when the row is in edit mode.
 

Scenario 1 : Apply row value based dynamic filters and display error and clear a cell in subform for invalid input

Organization: Zylker, a manufacturing company using Zoho CRM.

Subform Filtering: In the Quotes module, products in the subform are filtered based on the selected Product Category.

Stock Validation: When the quantity in the Quoted Items subform exceeds available Stock, an error message is displayed. The field is reset to null.

 

Click here to view the source code.

Scenario 2 : Secure subform rows with beforeRowDelete

  • Organization: Zylker ensures data integrity during key Deal stages in Zoho CRM.

  • Restricted Stages: Subform item deletion is restricted in the following stages:

    • Proposal/Price Quote

    • Negotiation/Review

    • Closed Won

    • Closed Lost

  • Enforcement: The beforeRowDelete event verifies the Deal stage and returns false to prevent deletion.

 

Click here to view the source code.

Scenario 3 : Auto-Fill values for new rows and clear subform based on custom conditionI

  • Module: Campaign module in Zoho CRM.

  • Auto-Population: When a new row is added to the subform:

    • The onRowAdd event uses setValue() to auto-populate:

      • "Status" field with "Planning".

      • "Allocated Budget" with $3000.

  • Region Change: When the "Region" field changes:

    • The onChange event triggers clear() to reset campaign details for region-specific data.

 

Click here to view the source code.

Scenario 4 : Tailor cell, row and column locks in subforms and manage field visibility with ease.

  • Module: Campaign subform in Zoho CRM.

  • Allocated Budget Field:

    • Editable only by admins.

    • Read-only for all other users.

  • Row Locking:

    • The setReadOnly() method, triggered by onLoad and onCellChange:

      • Locks the entire row when the Status is "Complete."

      • Restricts the Allocated Budget field unless the Status is "Planning."

  • Field Visibility:

    • The Type of Campaign column is managed with setVisibility():

      • Visible only when Parent Type is "others."

 

 

Click here to view the source code.

Scenario 5 : Dynamic data check on subform cell update

  • Validation: Ensure the Allocated Budget of all campaigns does not exceed the Total Budget Allocated.

  • Restriction:

    • If the budget exceeds the limit:

      • Prevent the row from being saved.

      • Display an error message.

 



Click here to view source the code.

Limitations :

1. The onRowAdd event is not supported during bulk row addition.

2. Subform methods and events do not work in line-item subforms present in Blueprint transition.
3. Row added in subforms using Guided selling  do not trigger the onRowAdd event
for now.
4. This update is not supported on mobile devices.

  

We hope you find this update useful!

QuoteRelease Plan : We have begun rolling out the feature and will provide updates here as it becomes available in each DC.

 

 





9 users like this announcement.
18 Replies
Reply
5 more
  • 9 days ago

This comes in PERFECT for us. Thank you Zoho Team!

When can we expect this to be activated in our account? 

  • 9 days ago

"2. Subform methods and events do not work in line-item subforms present in Blueprint transition."

What are "line-item Subforms present in Blueprint transition"?

  • 8 days ago

Hi, I cannot find those in my organization, could you please activate for me


  • 8 days ago

Hi
  and @Zohoboy

We're planning to make this support live across all DCs by next week. We'll keep this thread updated on its release progress.

Thanks!

This is a great addition! I can't wait to use this.

  • 6 days ago

Does this work on subforms in custom modules also?

  • 5 days ago

Hello Yadav,

Yes it will work for Subforms in the Custom modules as well.

Thank you!

  • Creator Certified Developer - Associate
  • 4 days ago

When will be the feature released for us?

  • 4 days ago

Hello Soham Patil,

We have planned to open the feature in the next week.

Thank you!

Hi, is this live in the US DC's or need to activated on an account by account basis?  

Thanks!

  • 3 days ago

Hello Adrian McCarroll,

We haven't opened it in US DC yet and planning to open by next week. For further assistance kindly reach our support(support@zohocrm.com).

Thank you!

Thanks .  So excited for this release - can see it being a total game changer for a number of our use cases!  

  • 12 hours ago

Wow, this is a really important release.. good job guys... I suppose these new subform events are triggered also when subforms are inline edited? and get new rows? without having to edit the whole record? the other recently released subform feature in the next link?

Reply to Maadhari MA
/* */
  • 12
  • Insert
  • Plain text
Add Comment
(Up to 20 MB )