Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

Custom JS not working on Entity Form, Web Page, Web Form

$
0
0

Hi All,

I have configured Customer Service Powerapps Portal and I want to validate "Profile Page" based on some fields.

Custome JS not working for Profile Web Page, I registered JS  under Profile Web Page -> Localized Content -> Advanced Tab -> Custom Javascript but it did not work.

Please suggest how to achieve this.

I tried below code snippet :


if (window.jQuery) {
(function ($) {
if (typeof (webFormClientValidate) != 'undefined') {
var originalValidationFunction = webFormClientValidate;
if (originalValidationFunction && typeof (originalValidationFunction) == "function") {
webFormClientValidate = function() {
originalValidationFunction.apply(this, arguments);
                      
                if($("#cr243_otp").val() === "")
                {
                    
                    alert("OTP required");
                    returnfalse;
                }
                else
                {
                    returntrue;
                }
};
}
}
}(window.jQuery));
}


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images