Site Map | About Us | Contact Us  
 The same content in Microsoft HTML help file format is included in the download package.

ScriptEvent Class

Provides a conveinent way to trigger server side event from JavaScript.

For a list of all members of this type, see ScriptEvent Members.

System.Object
   System.Web.UI.Control
      EO.Web.Control
         EO.Web.ScriptEvent

[Visual Basic]
Public Class ScriptEvent
    Inherits Control
[C#]
public class ScriptEvent : Control, IPostBackEventHandler

Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

Remarks

This control provides a conveinent to trigger server side event from JavaScript. To use the control, simply place a ScriptEvent in the form and then call client side JavaScript function eo_TriggerServerEvent to trigger the ScriptEvent's Command event:

[JavaScript] 
eo_TriggerServerEvent(
    "ScriptEvent1",     //ClientID of the ScriptEvent control
    "Anything",         //Command name
    "Whatever"          //Command argument
    );

The above code triggers server side Command event with the argument suplied. You can then handle the event accordingly.

ScriptEvent control can also be used to transfer additional data from client side to the server side. In order to use this feature, call addData or clearData on the client side. All data will be transferred to the server side through the ScriptEvent control's ClientData property.

Requirements

Namespace: EO.Web

Assembly: EO.Web (in EO.Web.dll)

See Also

ScriptEvent Members | EO.Web Namespace


Direct link to this topic