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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

How to change Form header Title

(0) ShareShare
ReportReport
Posted on by

How to change CRM Form Header Title because I have tried but it is not updating  on Page load event.

Can anyone give me life cycle of CRM???

So I can put code in preload event.

*This post is locked for comments

I have the same question (0)
  • a33ik Profile Picture
    84,331 Most Valuable Professional on at

    Hello,

    By default Form Header Title shows "New <Entity Type>" (Like New Contact or New Account) when user creates record and shows value of primary field when user edits record. What do you want to change?

  • Community Member Profile Picture
    on at

    Thanks Andrew for reply.

    Actually form is loading then Message is showing " New Account " after the Showing "CKS-001" as I wrote this code about this.but i wants to remove or hide "New Account" text because it is looking very odd.

    I hv tried to add style sheet for color change but it's not reflect becuase it is feature of dynamic  CRM.

    Can you please suggest how i can handle this?  

  • Verified answer
    gdas Profile Picture
    50,091 Moderator on at

    There is no supported way you can do this. However if you want unsupported way you can do this

    Register the following Javascript function on-load of the form.

    function ChangeFormTitle() {

       //Get form type

       var formType = Xrm.Page.ui.getFormType();

       //Get the form name

       var formName = Xrm.Page.ui.formSelector.getCurrentItem().getLabel();

       //Checking the form type is create

       if (formType == 1) {

           //Checking the form name

           if (formName == "Agreement") {

               //Changing the form title

               window.parent.document.getElementById("FormTitle").innerText = "New Agreement";

           }

           else if (formName == "Request") {

               window.parent.document.getElementById("FormTitle").innerText = "New Request";

           }

       }

    }

  • a33ik Profile Picture
    84,331 Most Valuable Professional on at

    Chandan,

    Can you please provide screenshot?

  • Community Member Profile Picture
    on at

    Thanks Goutam for it will not work because  replied .but where is put the code on form_load event but after that page already loaded.

    I am giving example ---

    1) when add new form like account then Form Header will show " New Account" after that your code will fire but i wants to hide "New Account" .

    is it possible ? dont know because there are no event like pre loaded.

    do you have any idea please provide me.

  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at

    Hi Chandan ,

    You can try with this. Please note that this is

    Not supported customization.

    window.parent.document.getElementById("FormTitle").style.display= "none";

  • Community Member Profile Picture
    on at

    Hi Gautam,

    Sorry but it will hide everytime ,when i have updated my new field after that it will not showing.

  • Verified answer
    gdas Profile Picture
    50,091 Moderator on at

    Hi Chandan,

    You can put one condition like form type or your label text to show hide in the same time.

  • Community Member Profile Picture
    on at

    Hi Goutam,

    Thanks for quick replied.

    I am explaining step by step.please see the below steps

    1. When page is loading then it is showing like "New User" 
    2. After that i have modifying every user like "Mr.XYZ"
    3. So I never apply condition any condition.
  • Suggested answer
    Community Member Profile Picture
    on at

    Thanks Goutam, I am using your logic and add one more logic and it will work.

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…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans