Examples: Exists() -- Security Role


The following example uses the Exists() function to indicate whether the LEAD GENERATION security role exists. If it does not, the role is added.

local string roleID;

roleID = "LEAD GENERATION";
if Exists(roleID) of form sySecurityRole = false then
	{Role does not exist, so create it}
	status = CreateSecurityRole(roleID, {ID}
		"Lead Generation", {Name}
		"Tasks include creating and updating customer leads.") {Description}
		of form sySecurityRole;
end if;


Documentation Feedback