Siebel Object Interfaces Reference > Invoking Custom Methods with MiniButton Controls >

Invoking Custom Methods with MiniButton Controls

Be sure to set the appropriate Target Browser Group in Siebel Tools.

To invoke a custom method with a MiniButton control

  1. Choose an applet (for example, Account List Applet) and create a control with the following properties:

    Name = ButtonTest
    Caption = Test
    HTML Type = MiniButton
    Method Invoked = MyTest

  2. Right click the applet and choose Edit Web Layout.

    The Web Layout Editor appears. The Controls/Columns window opens with the available controls, including the one you just created.

  3. Change the template mode in the Controls/Columns window to 4: Edit List.
  4. Drag and drop the ButtonTest control onto an available location. When you release the mouse button, the button appears.
  5. Click Save, and then close the Web Layout Editor.
  6. Enable the button using one of the following methods:
    • To enable the button declaratively, select the applet in the Object List Editor, expand the Applet object in the Object Explorer, select the Applet User Prop object, and then create a new user property for the applet in the Object List Editor:

      CanInvokeMethod: MyTest


      For more information on the CanInvokeMethod user property, see Siebel Developer's Reference.

      NOTE:  The declarative method is strongly recommended for performance reasons.

    • To add a server script to the applet, right-click the applet and choose Edit Server Scripts. Add the following script to the WebApplet_PreCanInvokeMethod() function.

      function WebApplet_PreCanInvokeMethod (MethodName, &CanInvoke)

      if (MethodName == "MyTest")


    CanInvoke = "TRUE";





  7. Add the following browser script to the applet you are using (for example, the Account List Applet):

    function Applet_PreInvokeMethod (name, inputPropSet)

    switch (name) {

      case "MyTest":

    theApplication().SWEAlert("Browser script!");






  8. Compile the applet object by right-clicking on it and then choosing Compile Selected Objects.
  9. Run any application that has access to accounts, and navigate to My Accounts.

    The new button appears.

  10. Click Test.

    The Browser Script displays an alert box indicating "Browser Script!"

Siebel Object Interfaces Reference Copyright © 2008, Oracle. All rights reserved.