Customizing the Busy Cursor to Display While a Business Service Executes

You can force a busy cursor to appear while a selected business service is executing. The example in this topic describes how to configure this behavior.

There is a system preference for Busy Cursor Timeout. For more information, see About Preferences.

To display a busy cursor while a Business Service executes

  1. Create an applet with a button that invokes an always-on method.

  2. Create a physical renderer to respond to the method invocation.

  3. Create a business service to be invoked.

    1. The following is an example of a business service.

      function Service_PreInvokeMethod (MethodName, Inputs, Outputs)
      {
      var nReturn = ContinueOperation;
      switch (MethodName) {
      case "ExampleMethod":
      var count;
      for (var i=1; i<4000000; i++) {
      Outputs.SetProperty("OutputProperty", "OutputValue");
      Outputs.SetProperty("ReturnedProperty", Inputs.GetProperty("InputProperty"));
      count++;
       }
      Return = CancelOperation;
      break;
      }
       return (nReturn);
      }
      
  4. Make sure the business service is invokable from the client using the application user property.

  5. Update the physical renderer to invoke the business service workOnBusyCursor control upon method invocation.

  6. Test your work:

    1. Navigate to any list applet, and then verify that it displays the control that you added.