Hi there All.
I want to add an Enable rule.
It is a custom rule via JS.
I have created a js web resource and place this function there :
function isInProgressOrRegistered() {
var userName=Xrm.Page.context.getUserName();
if(userName=="Adam Smith") {
return true;
} else {
return false;
}
}
Add this Library and function in Custom rule in Enable rules of RibbonWorkBench.
Here it is :

But when publish the solution the button in the ribbon disappear or the js function does not work.
What I am Doing wrong?
Thanks