C# Class WebChat.EventJS

显示文件 Open project: klean/anonymous-counseling-chat Class Usage Examples

Public Methods

Method Description
AddControlScript ( Page page, string eventName, Control control, string script ) : void
AddEventToAllSubmitItems ( Control ctrl, string eventString, string eventScript ) : void

Iterates through all the controls of the first control and recursiv calling this funktion again until the control has no more sub Controls. If one control is a Button or a LinkButton, the eventscript will be added to the event

SetWebControlEvent ( HtmlControl ctrl, string eventName, string script ) : void

Add an event to the Webcontrol if another event is assigned the script will be appended to the event

SetWebControlEvent ( System.Web.UI.UserControl ctrl, string eventName, string script ) : void

Add an event to the Webcontrol if another event is assigned the script will be appended to the event

SetWebControlEvent ( WebControl ctrl, string eventName, string script ) : void

Add an event to the Webcontrol if another event is assigned the script will be appended to the event

Method Details

AddControlScript() public static method

public static AddControlScript ( Page page, string eventName, Control control, string script ) : void
page System.Web.UI.Page
eventName string
control System.Web.UI.Control
script string
return void

AddEventToAllSubmitItems() public static method

Iterates through all the controls of the first control and recursiv calling this funktion again until the control has no more sub Controls. If one control is a Button or a LinkButton, the eventscript will be added to the event
public static AddEventToAllSubmitItems ( Control ctrl, string eventString, string eventScript ) : void
ctrl System.Web.UI.Control The Control to iterate through
eventString string the name of the event to assign
eventScript string The script to assign to the event
return void

SetWebControlEvent() public static method

Add an event to the Webcontrol if another event is assigned the script will be appended to the event
public static SetWebControlEvent ( HtmlControl ctrl, string eventName, string script ) : void
ctrl System.Web.UI.HtmlControls.HtmlControl The WebControl to add the event to eg. a button
eventName string The name of the event eg. onclick
script string The Script to call when the event is fired
return void

SetWebControlEvent() public static method

Add an event to the Webcontrol if another event is assigned the script will be appended to the event
public static SetWebControlEvent ( System.Web.UI.UserControl ctrl, string eventName, string script ) : void
ctrl System.Web.UI.UserControl The WebControl to add the event to eg. a button
eventName string The name of the event eg. onclick
script string The Script to call when the event is fired
return void

SetWebControlEvent() public static method

Add an event to the Webcontrol if another event is assigned the script will be appended to the event
public static SetWebControlEvent ( WebControl ctrl, string eventName, string script ) : void
ctrl System.Web.UI.WebControls.WebControl The WebControl to add the event to eg. a button
eventName string The name of the event eg. onclick
script string The Script to call when the event is fired
return void