Upgrade Guide for Microsoft Windows > Migrating Client Configurations > Migrating Scripts >

Migrating Scripts Attached to Controls


In Release 7.x, the ControlName_Click event handler was replaced by the Method Invoked property on control objects. By specifying the Method Invoked property, when a user clicks on a control (for example, a Button), the client framework checks to see if the method was implemented in browser script associated with the Applet_PreInvokeMethod event.

In addition to the obsolescence of the ControlName_Click event handler, control methods that were formerly available in Siebel VB or eScript are no longer available. In Release 7.x, all control methods are available through browser scripting and execute in the high interactivity applications only. Table 29 provides a list of the control methods that are supported by browser script. For more information, see Siebel Tools Online Help.

Table 29.  Control Method Syntax Summary
Method
Description
Syntax
Applet
Returns the parent applet for the control.
var oControl;
var oApplet;
oApplet = oControl.Applet();
Buscomp
Returns the corresponding business component for the control.
var oControl;
var busComp;
busComp = oControl.Buscomp();
GetValue
Returns the value of a control.
var oControl;
var sValue;
sValue = oControl.GetValue();
Name
Returns the name of the control.
var oControl;
var sName;
sName = oControl.Name();
SetValue
Sets the contents of the control to the indicated value.
var oControl;
oControl.SetValue(value);

In addition to specifying the "Method Invoked" property, controls may also be scripted based upon native DOM events supported by the browser. Figure 11 depicts the DOM events that may be scripted when a MiniButton control is added to an applet. The scripting of control-based DOM events is supported by high and standard interactivity applications and must be implemented in JavaScript.

Figure 11.  DOM Events When MiniButton Control Added to Applet
Click for full size image

 Upgrade Guide for Microsoft Windows
 Published: 20 October 2003