Button should be displayed as enabled only for the user SADMIN
Hi all,
the client requirement is to show the Siebel standard button "Delete" as enabled only for the user SADMIN on a specific applet, but as disabled for the rest of users.
I tried with the following code, but it is not working. The applet is showing a weird layout and no button are being displayed (buttons New and Query for example):
if (MethodName == "DeleteRecord"){
if(TheApplication().GetProfileAttr("Me.Login") == "SADMIN")
{
CanInvoke = "TRUE";
return (CancelOperation);
}
else
{
CanInvoke = "FALSE";
return (CancelOperation);
}
}
The code is written in the WebApplet Pre_CanInvoke.
What is going on? Can please somebody help us?.
Regards