Platform

 View Only

 Eval in Button where Users.Role is in ("Cloud Reports","Showback Bill")

Jump to  Best Answer
  • TBMStudio
Dawn Kassube's profile image
Dawn Kassube posted Mon April 15, 2024 05:33 PM

I am attempting to enter an Eval statement in the button on the Service Costing Report and need assistance.  How do you state if the Users.Role is IN 2 roles, then it is disabled else enabled.  I tried the following but it did not work. 

<%=IF(eval("{$CurrentUser}:{Users.Role}") =("Cloud Reports" OR "Showback Bill"),"disabled","enabled")%>

Thank you,

Dawn


#TBMStudio
Dan Kelly's profile image
Dan Kelly  Best Answer

Try this:
<%=if(eval("=$CurrentUser:Users.Role")="Cloud Reports" OR eval("=$CurrentUser:Users.Role")="Showback Bill","disabled","enabled")%>


#TBMStudio
Dawn Kassube's profile image
Dawn Kassube

Thank you Daniel!  This worked.


#TBMStudio