CRM2013: Getting current form name via JavaScript

Today i had to write a function that worked on a particular form at a current stage within a business process flow. The snippet below shows how you can retrieve the name of the current form.

function getCurrentFormName() {
    var formName = Xrm.Page.ui.formSelector.getCurrentItem().getLabel();
    if (formName == 'Lead Referrer Form') {
       //add your code here....


Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.