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)

Need to add liquid template for rendering the button which is set in entity form

(0) ShareShare
ReportReport
Posted on by 340

Need to add liquid template for rendering the button which is set in entity form through web template i am not able to render the button which i have set in entity form. So, please help me out 

*This post is locked for comments

I have the same question (0)
  • joman Profile Picture
    617 on at

    Button on a form?

    Do you need something like this:

    8738.12.png

    ??

  • Alok Sharma Profile Picture
    340 on at

    Yes but after adding style sheet of header and footer.....

  • Andreas Cieslik Profile Picture
    9,267 on at

    Can you show us the liquid part of your entity form where you defined the button?

  • Verified answer
    joman Profile Picture
    617 on at

    i've done this by JS.

    1. I created an empty(1x1px) picture.

    2. I made a web-resource on a form and chose this picture.

    3. On needed event (on form load for example) i place js witch call function:

    function toButton(text, WebResource, width, eventName) {
            var ctrl = Xrm.Page.getControl(WebResource).getObject();
            if (ctrl) {
                var Btn = document.createElement("input");
                Btn.type = "button";
                Btn.value = text;
                Btn.style.width = width;
                Btn.addEventListener('click', eventName);
                ctrl.parentNode.replaceChild(Btn, ctrl);
            }
        }

    You can modify it to make any style of button.

  • Suggested answer
    Andreas Cieslik Profile Picture
    9,267 on at

    this reference is showing that CRM form scripting is not working in Portal rendering:

    community.adxstudio.com/.../crm-entity-form-feature-matrix

    On the Entity form there is a Custom JavaScript field where you can put in your own modification via jQuery:

    community.adxstudio.com/.../custom-javascript

    with a bit of trial and error you should be able to get the web resource control and create the required button via jQuery.

  • Verified answer
    Alok Sharma Profile Picture
    340 on at

    It can be possible while redirecting a web page of on successful display field in entity form.

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