How to Invoke a Business Service from Browser Script in Siebel

7/11/2012 No Comment

Invoke a Business Service from Browser Script in Siebel.

Siebel Business Services in Siebel can contain both server and browser script. Business service methods execute within the browser if they are written in browser script or on the server if they are written in server script. This section describes how to invoke business service methods written in server script from an applet
browser script.

First, it is important to note that a server script cannot be directly called from a browser script; invoking a server script from a browser script is an implicit operation. The interaction manager on the Siebel Smart Web Client processes requests to invoke methods on business services.

If either of the PreInvokeMethod events returns CancelOperation, the sequence is aborted.

Siebel Business Services can contain any combination of browser and server script,which allows services to exist that contain only browser script or only server script. Siebel Business Services that contain only browser script will execute exclusively on the browser, while those that contain only server script will execute exclusively on the server. This example uses a business service that contains only server script. This way, an applet script can invoke a method on, and retrieve a return value from, a server script.

The primary reason a developer would want to invoke a server script from a browser script is that it is not possible to execute queries on arbitrary business components from browser script.

The Siebel Object Interfaces available to browser script are a subset of those available to server script and do not include the business component methods such as ClearToQuery(), ExecuteQuery(), FirstRecord(), and so on needed to query the database.

As a result, to execute a query, update fields, or interact with the database at all,
server script must be used. In many cases this does not require both browser and server script, as the developer can write all the script on server events. In the case that browser script must be used to trigger a server script (most often for some sort of field-level validation).
Related Posts

No comments :


Aired | The content is copyrighted and may not be reproduced on other websites. | Copyright © 2009-2016 | All Rights Reserved 2016

Contact Us | About Us | Privacy Policy and Disclaimer