Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 4

Custom Buttons in Siebel-Lession 6

How to Enable a Customized button on an Applet?

Answer:
1) Script
2) Applet User Property

1) Script

Step 1: Created a new control by name "CustomButton" and gave the HTML type
as "Mini button" Also gave Method Invoked as some name.

By Example: Name: Button For New Record


HTML type: MiniButton
Method Invoked: ABC

Step 2: Added the button in the Edit web Layout and Compiled for output.

Step 3: then choose Edit Server Scripts.


Step 4: Add the following script to the WebApplet_PreCanInvokeMethod()
function

if (MethodName == "ABC")
{
CanInvoke = "True";
return (CancelOperation);
}

Step 5: Add the following script to the WebApplet_PreInvokeMethod() function

function WebApplet_PreInvokeMethod (MethodName)


{
if (MethodName == "ABC")
{
this.InvokeMethod("NewRecord");
return (CancelOperation);
}
return (ContinueOperation);
}

Here Am Replicate Function of New Record


Step 6: Now Compile Applet and See the changes in client

2)Applet User Property

Create an applet user user property with the following details :

Name = CanInvokeMethod: ABC

Value = TRUE

Note:- space is mandatory between


CanInvokeMethod: and <MethodName> . Button
will not enable if you dont put space in user
property.

You might also like