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)

Setting up JavaScript action onload of a page

(0) ShareShare
ReportReport
Posted on by

I am trying to set up a site-wide login function using JavaScript, I need this to load when a user opens an Opportunity form.

I set up the general JavaScript to run onload of the Opportunities page but I need one section to specifically run.  just one function:

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Bruno Lucas Profile Picture
    5,421 on at
    RE: Setting up JavaScript action onload of a page

    Hi,

    What do you mean BY "site-wide login function"

    if you want only one function you just need to specify.  on the library field you enter the name of the JavaScript file.

    On the "Function" field you enter the name of the JavaScript function\method without ()

    however, this is only running 1 js function when open an opportunity.

  • Community Member Profile Picture
    on at
    RE: Setting up JavaScript action onload of a page

    This is exactly what I did but it does not seem to be executing on the page load.

  • Suggested answer
    Mahadeo Matre Profile Picture
    17,021 on at
    RE: Setting up JavaScript action onload of a page

    Hi..

    There might be, you forgot to publish form/ customization after adding script.

    Once published, try using CTRL+F5 to refresh your form, it is not worked then try by clearing browser cache.

    Also you can debug your JavaScript using IE developer Tools.

    Here are details how to debug

    msdn.microsoft.com/.../gg699336(v=vs.85).aspx

    msdn.microsoft.com/.../dd565625(v=vs.85).aspx

    Hope this will help..

  • Bruno Lucas Profile Picture
    5,421 on at
    RE: Setting up JavaScript action onload of a page

    yes. unless you save and publish it won't deploy.

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

#1
UllrSki Profile Picture

UllrSki 2

#3
ED-30091530-0 Profile Picture

ED-30091530-0 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans